diff --git a/ChangeLog.md b/ChangeLog.md
--- a/ChangeLog.md
+++ b/ChangeLog.md
@@ -1,3 +1,8 @@
+# 6.5.0.0
+
+  - Import Bibutils 6.5.
+
+
 # 6.4.0.0
 
   - Import Bibutils 6.4.
diff --git a/bibutils/adsout.c b/bibutils/adsout.c
--- a/bibutils/adsout.c
+++ b/bibutils/adsout.c
@@ -71,6 +71,7 @@
 	TYPE_DIPLOMATHESIS,
 	TYPE_DOCTORALTHESIS,
 	TYPE_HABILITATIONTHESIS,
+	TYPE_LICENTIATETHESIS,
 	TYPE_PATENT,
 	TYPE_PROGRAM
 };
@@ -93,10 +94,12 @@
 		{ "Diploma thesis",            TYPE_DIPLOMATHESIS },
 		{ "Doctoral thesis",           TYPE_DOCTORALTHESIS },
 		{ "Habilitation thesis",       TYPE_HABILITATIONTHESIS },
+		{ "Licentiate thesis",         TYPE_LICENTIATETHESIS },
 		{ "legislation",               TYPE_BILL },
 		{ "newspaper",                 TYPE_NEWSPAPER },
 		{ "communication",             TYPE_COMMUNICATION },
 		{ "manuscript",                TYPE_MANUSCRIPT },
+		{ "unpublished",               TYPE_MANUSCRIPT },
 		{ "report",                    TYPE_REPORT },
 		{ "technical report",          TYPE_REPORT },
 		{ "legal case and case notes", TYPE_CASE },
diff --git a/bibutils/biblatexin.c b/bibutils/biblatexin.c
--- a/bibutils/biblatexin.c
+++ b/bibutils/biblatexin.c
@@ -339,7 +339,12 @@
 	str_empty( data );
 
 	p = biblatex_tag( p, tag );
-	if ( tag->len==0 ) return p;
+	if ( str_is_empty( tag ) ) {
+		/* ...skip this line */
+		while ( *p && *p!='\n' && *p!='\r' ) p++;
+		while ( *p=='\n' || *p=='\r' ) p++;
+		return p;
+	}
 
 	slist_init( &tokens );
 
@@ -371,18 +376,21 @@
 process_cite( fields *bibin, char *p, char *filename, long nref, param *pm )
 {
 	int fstatus, status = BIBL_OK;
-	str tag, data;
-	strs_init( &tag, &data, NULL );
-	p = process_biblatextype( p, &data );
-	if ( str_has_value( &data ) ) {
-		fstatus = fields_add( bibin, "INTERNAL_TYPE", str_cstr( &data ), 0 );
-		if ( fstatus!=FIELDS_OK ) { status = BIBL_ERR_MEMERR; goto out; }
-	}
-	p = process_biblatexid ( p, &data );
-	if ( str_has_value( &data ) ) {
-		fstatus = fields_add( bibin, "REFNUM", str_cstr( &data ), 0 );
-		if ( fstatus!=FIELDS_OK ) { status = BIBL_ERR_MEMERR; goto out; }
-	}
+	str type, id, tag, data;
+
+	strs_init( &type, &id, &tag, &data, NULL );
+
+	p = process_biblatextype( p, &type );
+	p = process_biblatexid( p, &id );
+
+	if ( str_is_empty( &type ) || str_is_empty( &id ) ) goto out;
+
+	fstatus = fields_add( bibin, "INTERNAL_TYPE", str_cstr( &type ), 0 );
+	if ( fstatus!=FIELDS_OK ) { status = BIBL_ERR_MEMERR; goto out; }
+
+	fstatus = fields_add( bibin, "REFNUM", str_cstr( &id ), 0 );
+	if ( fstatus!=FIELDS_OK ) { status = BIBL_ERR_MEMERR; goto out; }
+
 	while ( *p ) {
 		p = process_biblatexline( p, &tag, &data, 1, nref, pm );
 		if ( !p ) { status = BIBL_ERR_MEMERR; goto out; }
@@ -394,7 +402,7 @@
 		strs_empty( &tag, &data, NULL );
 	}
 out:
-	strs_free( &tag, &data, NULL );
+	strs_free( &type, &id, &tag, &data, NULL );
 	return status;
 }
 
diff --git a/bibutils/bibtexin.c b/bibutils/bibtexin.c
--- a/bibutils/bibtexin.c
+++ b/bibutils/bibtexin.c
@@ -349,8 +349,14 @@
 	str_empty( data );
 
 	p = bibtex_tag( p, tag );
-	if ( p==NULL || str_is_empty( tag ) ) return p;
 
+	if ( str_is_empty( tag ) ) {
+		/* ...skip this line */
+		while ( *p && *p!='\n' && *p!='\r' ) p++;
+		while ( *p=='\n' || *p=='\r' ) p++;
+		return p;
+	}
+
 	slist_init( &tokens );
 
 	if ( *p=='=' ) {
@@ -387,22 +393,21 @@
 process_cite( fields *bibin, char *p, char *filename, long nref, param *pm )
 {
 	int fstatus, status = BIBL_OK;
-	str tag, data;
+	str type, id, tag, data;
 
-	strs_init( &tag, &data, NULL );
+	strs_init( &type, &id, &tag, &data, NULL );
 
-	p = process_bibtextype( p, &data );
-	if ( str_has_value( &data ) ) {
-		fstatus = fields_add( bibin, "INTERNAL_TYPE", str_cstr( &data ), 0 );
-		if ( fstatus!=FIELDS_OK ) { status = BIBL_ERR_MEMERR; goto out; }
-	}
+	p = process_bibtextype( p, &type );
+	p = process_bibtexid( p, &id );
 
-	p = process_bibtexid( p, &data );
-	if ( str_has_value( &data ) ) {
-		fstatus = fields_add( bibin, "REFNUM", str_cstr( &data ), 0 );
-		if ( fstatus!=FIELDS_OK ) { status = BIBL_ERR_MEMERR; goto out; }
-	}
+	if ( str_is_empty( &type ) || str_is_empty( &id ) ) goto out;
 
+	fstatus = fields_add( bibin, "INTERNAL_TYPE", str_cstr( &type ), 0 );
+	if ( fstatus!=FIELDS_OK ) { status = BIBL_ERR_MEMERR; goto out; }
+
+	fstatus = fields_add( bibin, "REFNUM", str_cstr( &id), 0 );
+	if ( fstatus!=FIELDS_OK ) { status = BIBL_ERR_MEMERR; goto out; }
+
 	while ( *p ) {
 		p = process_bibtexline( p, &tag, &data, 1, bibin, nref, pm );
 		if ( p==NULL ) { status = BIBL_ERR_MEMERR; goto out; }
@@ -414,7 +419,7 @@
 		strs_empty( &tag, &data, NULL );
 	}
 out:
-	strs_free( &tag, &data, NULL );
+	strs_free( &type, &id, &tag, &data, NULL );
 	return status;
 }
 
@@ -1006,12 +1011,19 @@
 	if ( !strncasecmp( str_cstr( invalue ), "Diplom", 6 ) ) {
 		fstatus = fields_replace_or_add( bibout, "GENRE:BIBUTILS", "Diploma thesis", level );
 		if ( fstatus!=FIELDS_OK ) status = BIBL_ERR_MEMERR;
-	} else if ( !strncasecmp( str_cstr( invalue ), "Habilitation", 13 ) ) {
+	}
+	else if ( !strncasecmp( str_cstr( invalue ), "HSabilitation", 13 ) ) {
 		fstatus = fields_replace_or_add( bibout, "GENRE:BIBUTILS", "Habilitation thesis", level );
 		if ( fstatus!=FIELDS_OK ) status = BIBL_ERR_MEMERR;
-	} else if ( is_embedded_link( str_cstr( invalue ) ) ) {
+	}
+	else if ( !strncasecmp( str_cstr( invalue ), "Licentiate", 10 ) ) {
+		fstatus = fields_replace_or_add( bibout, "GENRE:BIBUTILS", "Licentiate thesis", level );
+		if ( fstatus!=FIELDS_OK ) status = BIBL_ERR_MEMERR;
+	}
+	else if ( is_embedded_link( str_cstr( invalue ) ) ) {
 		status =  urls_split_and_add( str_cstr( invalue ), bibout, level );
-	} else {
+	}
+	else {
 		fstatus = fields_add( bibout, "PUBLISHER", str_cstr( invalue ), level );
 		if ( fstatus!=FIELDS_OK ) status = BIBL_ERR_MEMERR;
 	}
diff --git a/bibutils/bibtexout.c b/bibutils/bibtexout.c
--- a/bibutils/bibtexout.c
+++ b/bibutils/bibtexout.c
@@ -58,6 +58,7 @@
 	TYPE_BOOK,
 	TYPE_PHDTHESIS,
 	TYPE_MASTERSTHESIS,
+	TYPE_DIPLOMATHESIS,
 	TYPE_REPORT,
 	TYPE_MANUAL,
 	TYPE_UNPUBLISHED,
@@ -106,7 +107,8 @@
 			type = TYPE_ARTICLE;
 		} else if ( !strcasecmp( genre, "instruction" ) ) {
 			type = TYPE_MANUAL;
-		} else if ( !strcasecmp( genre, "unpublished" ) ) {
+		} else if ( !strcasecmp( genre, "unpublished" ) ||
+		            !strcasecmp( genre, "manuscript" ) ) {
 			type = TYPE_UNPUBLISHED;
 		} else if ( !strcasecmp( genre, "conference publication" ) ) {
 			if ( level==0 ) type=TYPE_PROCEEDINGS;
@@ -126,8 +128,12 @@
 			if ( type==TYPE_UNKNOWN ) type=TYPE_PHDTHESIS;
 		} else if ( !strcasecmp( genre, "Ph.D. thesis" ) ) {
 			type = TYPE_PHDTHESIS;
+		} else if ( !strcasecmp( genre, "Licentiate thesis" ) ) {
+			type = TYPE_PHDTHESIS;
 		} else if ( !strcasecmp( genre, "Masters thesis" ) ) {
 			type = TYPE_MASTERSTHESIS;
+		} else if ( !strcasecmp( genre, "Diploma thesis" ) ) {
+			type = TYPE_DIPLOMATHESIS;
 		} else if ( !strcasecmp( genre, "electronic" ) ) {
 			type = TYPE_ELECTRONIC;
 		} else if ( !strcasecmp( genre, "miscellaneous" ) ) {
@@ -241,6 +247,7 @@
 		[ TYPE_BOOK          ] = "Book",
 		[ TYPE_PHDTHESIS     ] = "PhdThesis",
 		[ TYPE_MASTERSTHESIS ] = "MastersThesis",
+		[ TYPE_DIPLOMATHESIS ] = "MastersThesis",
 		[ TYPE_REPORT        ] = "TechReport",
 		[ TYPE_MANUAL        ] = "Manual",
 		[ TYPE_COLLECTION    ] = "Collection",
@@ -788,6 +795,30 @@
 	}
 }
 
+static void
+append_howpublished( fields *in, fields *out, int *status )
+{
+	int n, fstatus;
+	char *d;
+
+	n = fields_find( in, "GENRE:BIBUTILS", LEVEL_ANY );
+	if ( n==FIELDS_NOTFOUND ) return;
+
+	d = fields_value( in, n, FIELDS_CHRP_NOUSE );
+	if ( !strcmp( d, "Habilitation thesis" ) ) {
+		fstatus = fields_add( out, "howpublised", d, LEVEL_MAIN );
+		if ( fstatus!=FIELDS_OK ) *status = BIBL_ERR_MEMERR;
+	}
+	if ( !strcmp( d, "Licentiate thesis" ) ) {
+		fstatus = fields_add( out, "howpublised", d, LEVEL_MAIN );
+		if ( fstatus!=FIELDS_OK ) *status = BIBL_ERR_MEMERR;
+	}
+	if ( !strcmp( d, "Diploma thesis" ) ) {
+		fstatus = fields_add( out, "howpublised", d, LEVEL_MAIN );
+		if ( fstatus!=FIELDS_OK ) *status = BIBL_ERR_MEMERR;
+	}
+}
+
 static int
 append_data( fields *in, fields *out, param *p, unsigned long refnum )
 {
@@ -828,6 +859,7 @@
 	append_simple      ( in, "EPRINTCLASS",        "primaryClass", out, &status );
 	append_isi         ( in, out, &status );
 	append_simple      ( in, "LANGUAGE",           "language",  out, &status );
+	append_howpublished( in, out, &status );
 
 	return status;
 }
diff --git a/bibutils/bu_auth.c b/bibutils/bu_auth.c
--- a/bibutils/bu_auth.c
+++ b/bibutils/bu_auth.c
@@ -21,6 +21,7 @@
 	"handwritten note",
 	"hearing",
 	"journal article",
+	"Licentiate thesis",
 	"magazine",
 	"magazine article",
 	"manuscript",
diff --git a/bibutils/endout.c b/bibutils/endout.c
--- a/bibutils/endout.c
+++ b/bibutils/endout.c
@@ -89,6 +89,7 @@
 	TYPE_DIPLOMATHESIS,               /* Thesis */
 	TYPE_DOCTORALTHESIS,              /* Thesis */
 	TYPE_HABILITATIONTHESIS,          /* Thesis */
+	TYPE_LICENTIATETHESIS,            /* Thesis */
 	TYPE_UNPUBLISHED,                 /* Unpublished Work */
 };
 
@@ -252,6 +253,7 @@
 		{ "Diploma thesis",            TYPE_DIPLOMATHESIS },
 		{ "Doctoral thesis",           TYPE_DOCTORALTHESIS },
 		{ "Habilitation thesis",       TYPE_HABILITATIONTHESIS },
+		{ "Licentiate thesis",         TYPE_LICENTIATETHESIS },
 		{ "communication",             TYPE_COMMUNICATION },
 		{ "manuscript",                TYPE_MANUSCRIPT },
 		{ "unpublished",               TYPE_UNPUBLISHED },
@@ -636,6 +638,10 @@
 		fstatus = fields_add( out, "%9", "Habilitation thesis", LEVEL_MAIN );
 		if ( fstatus!=FIELDS_OK ) *status = BIBL_ERR_MEMERR;
 	}
+	else if ( type==TYPE_LICENTIATETHESIS ) {
+		fstatus = fields_add( out, "%9", "Licentiate thesis", LEVEL_MAIN );
+		if ( fstatus!=FIELDS_OK ) *status = BIBL_ERR_MEMERR;
+	}
 }
 
 static void
@@ -695,14 +701,24 @@
 	append_people( in, "AUTHOR",     "%Y", LEVEL_SERIES, out, &status );
 	append_people( in, "EDITOR",     "%Y", LEVEL_SERIES, out, &status );
 
-	if ( type==TYPE_CASE )
+	if ( type==TYPE_CASE ) {
 		append_easy(    in, "AUTHOR:CORP", "%I", LEVEL_MAIN, out, &status );
-	else if ( type==TYPE_HEARING )
+		append_easy(    in, "AUTHOR:ASIS", "%I", LEVEL_MAIN, out, &status );
+	}
+	else if ( type==TYPE_HEARING ) {
 		append_easyall( in, "AUTHOR:CORP", "%S", LEVEL_MAIN, out, &status );
-	else if ( type==TYPE_NEWSARTICLE )
-		append_people(  in, "REPORTER",    "%A", LEVEL_MAIN, out, &status );
-	else if ( type==TYPE_COMMUNICATION )
-		append_people(  in, "RECIPIENT",   "%E", LEVEL_ANY,  out, &status  );
+		append_easyall( in, "AUTHOR:ASIS", "%S", LEVEL_MAIN, out, &status );
+	}
+	else if ( type==TYPE_NEWSARTICLE ) {
+		append_people(  in, "REPORTER",        "%A", LEVEL_MAIN, out, &status );
+		append_people(  in, "REPORTER:CORP",   "%A", LEVEL_MAIN, out, &status );
+		append_people(  in, "REPORTER:ASIS",   "%A", LEVEL_MAIN, out, &status );
+	}
+	else if ( type==TYPE_COMMUNICATION ) {
+		append_people(  in, "ADDRESSEE",       "%E", LEVEL_ANY,  out, &status  );
+		append_people(  in, "ADDRESSEE:CORP",  "%E", LEVEL_ANY,  out, &status  );
+		append_people(  in, "ADDRESSEE:ASIS",  "%E", LEVEL_ANY,  out, &status  );
+	}
 	else {
 		append_easyall( in, "AUTHOR:CORP",     "%A", LEVEL_MAIN, out, &status );
 		append_easyall( in, "AUTHOR:ASIS",     "%A", LEVEL_MAIN, out, &status );
diff --git a/bibutils/endtypes.c b/bibutils/endtypes.c
--- a/bibutils/endtypes.c
+++ b/bibutils/endtypes.c
@@ -405,7 +405,7 @@
 	{ "%Q", "TRANSLATEDTITLE", SIMPLE, LEVEL_MAIN },
 	{ "%D", "DATE:YEAR",       SIMPLE, LEVEL_MAIN },
 	{ "%T", "TITLE" ,          TITLE,  LEVEL_MAIN },
-	{ "%E", "RECIPIENT",       PERSON, LEVEL_MAIN },
+	{ "%E", "ADDRESSEE",       PERSON, LEVEL_MAIN },
 	{ "%C", "ADDRESS",         SIMPLE, LEVEL_MAIN },
 	{ "%V", "VOLUME",          SIMPLE, LEVEL_MAIN },
 	{ "%I", "PUBLISHER",       SIMPLE, LEVEL_MAIN },
diff --git a/bibutils/marc_auth.c b/bibutils/marc_auth.c
--- a/bibutils/marc_auth.c
+++ b/bibutils/marc_auth.c
@@ -101,7 +101,7 @@
 	"web site",
 	"yearbook",
 };
-static int nmarc_genre = sizeof( marc_genre ) / sizeof( const char* );
+static const int nmarc_genre = sizeof( marc_genre ) / sizeof( const char* );
 
 static const char *marc_resource[] = {
 	"cartographic",
@@ -117,7 +117,308 @@
 	"text",
 	"three dimensional object"
 };
-static int nmarc_resource = sizeof( marc_resource ) / sizeof( const char* );
+static const int nmarc_resource = sizeof( marc_resource ) / sizeof( const char* );
+
+
+/* www.loc.gov/marc/relators/relacode.html */
+
+typedef struct marc_trans {
+	char *abbreviation;
+	char *internal_name;
+} marc_trans;
+
+static const marc_trans relators[] = {
+	{ "abr",	"ABRIDGER"                     },	/* Abridger */
+	{ "acp",	"ART_COPYIST"                  },	/* Art copyist */
+	{ "act",	"ACTOR"                        },	/* Actor */
+	{ "adi", 	"ART_DIRECTOR"                 },	/* Art director */
+	{ "adp",	"ADAPTER"                      },	/* Adapter */
+	{ "aft",	"AUTHOR"                       },	/* Author of afterword, colophon, etc. */
+	{ "anl",	"ANALYST"                      }, 	/* Analyst */
+	{ "anm",	"ANIMATOR"                     },	/* Animator */
+	{ "ann",	"ANNOTATOR"                    },	/* Annotator */
+	{ "ant",	"BIBLIOGRAPHIC_ANTECENDENT"    },	/* Bibliographic antecedent */
+	{ "ape",	"APPELLEE"                     },	/* Appellee */
+	{ "apl",	"APPELLANT"                    }, 	/* Appellant */
+	{ "app",	"APPLICANT"                    },	/* Applicant */
+	{ "aqt",	"AUTHOR"                       },	/* Author in quotations or text abstracts */
+	{ "arc",	"ARCHITECT"                    },	/* Architect */
+	{ "ard",	"ARTISTIC_DIRECTOR"            },	/* Artistic director */
+	{ "arr",	"ARRANGER"                     },	/* Arranger */
+	{ "art",	"ARTIST"                       },	/* Artist */
+	{ "asg",	"ASSIGNEE"                     },	/* Assignee */
+	{ "asn",	"ASSOCIATED_NAME"              },	/* Associated name */
+	{ "ato",	"AUTOGRAPHER"                  },	/* Autographer */
+	{ "att",	"ATTRIBUTED_NAME"              },	/* Attributed name */
+	{ "auc",	"AUCTIONEER"                   },	/* Auctioneer */
+	{ "aud",	"AUTHOR"                       },	/* Author of dialog */
+	{ "aui",	"AUTHOR"                       },	/* Author of introduction, etc. */
+	{ "aus",	"AUTHOR"                       },	/* Screenwriter */
+	{ "aut",	"AUTHOR"                       },	/* Author */
+	{ "author",     "AUTHOR"                       },
+	{ "bdd",	"BINDING_DESIGNER"             },	/* Binding designer */
+	{ "bjd",	"BOOKJACKET_DESIGNER"          },	/* Bookjacket designer */
+	{ "bkd",	"BOOK_DESIGNER"                },	/* Book designer */
+	{ "bkp",	"BOOK_PRODUCER"                },	/* Book producer */
+	{ "blw",	"AUTHOR"                       },	/* Blurb writer */
+	{ "bnd",	"BINDER"                       },	/* Binder */
+	{ "bpd",	"BOOKPLATE_DESIGNER"           },	/* Bookplate designer */
+	{ "brd",	"BROADCASTER"                  },	/* Broadcaster */
+	{ "brl",	"BRAILLE_EMBOSSER"             },	/* Braille embosser */
+	{ "bsl",	"BOOKSELLER"                   },	/* Bookseller */
+	{ "cas",	"CASTER"                       },	/* Caster */
+	{ "ccp",	"CONCEPTOR"                    },	/* Conceptor */
+	{ "chr",	"CHOREOGRAPHER"                },	/* Choreographer */
+	{ "clb",	"COLLABORATOR"                 },	/* Collaborator */
+	{ "cli",	"CLIENT"                       },	/* Client */
+	{ "cll",	"CALLIGRAPHER"                 },	/* Calligrapher */
+	{ "clr",	"COLORIST"                     },	/* Colorist */
+	{ "clt",	"COLLOTYPER"                   },	/* Collotyper */
+	{ "cmm",	"COMMENTATOR"                  },	/* Commentator */
+	{ "cmp",	"COMPOSER"                     },	/* Composer */
+	{ "cmt",	"COMPOSITOR"                   },	/* Compositor */
+	{ "cnd",	"CONDUCTOR"                    },	/* Conductor */
+	{ "cng",	"CINEMATOGRAPHER"              },	/* Cinematographer */
+	{ "cns",	"CENSOR"                       },	/* Censor */
+	{ "coe",	"CONTESTANT-APPELLEE"          },	/* Contestant-appellee */
+	{ "col",	"COLLECTOR"                    },	/* Collector */
+	{ "com",	"COMPILER"                     },	/* Compiler */
+	{ "con",	"CONSERVATOR"                  },	/* Conservator */
+	{ "cor",	"COLLECTION_REGISTRAR"         },	/* Collection registrar */
+	{ "cos",	"CONTESTANT"                   },	/* Contestant */
+	{ "cot",	"CONTESTANT-APPELLANT"         },	/* Contestant-appellant */
+	{ "cou",	"COURT_GOVERNED"               },	/* Court governed */
+	{ "cov",	"COVER_DESIGNER"               },	/* Cover designer */
+	{ "cpc",	"COPYRIGHT_CLAIMANT"           },	/* Copyright claimant */
+	{ "cpe",	"COMPLAINANT-APPELLEE"         },	/* Complainant-appellee */
+	{ "cph",	"COPYRIGHT_HOLDER"             },	/* Copyright holder */
+	{ "cpl",	"COMPLAINANT"                  },	/* Complainant */
+	{ "cpt",	"COMPLAINANT-APPELLANT"        },	/* Complainant-appellant */
+	{ "cre",	"AUTHOR"                       },	/* Creator */
+	{ "creator",    "AUTHOR"                       },
+	{ "crp",	"CORRESPONDENT"                },	/* Correspondent */
+	{ "crr",	"CORRECTOR"                    },	/* Corrector */
+	{ "crt",	"COURT_REPORTER"               },	/* Court reporter */
+	{ "csl",	"CONSULTANT"                   },	/* Consultant */
+	{ "csp",	"CONSULTANT_TO_A_PROJECT"      },	/* Consultant to a project */
+	{ "cst",	"COSTUME_DESIGNER"             },	/* Costume designer */
+	{ "ctb",	"CONTRIBUTOR"                  },	/* Contributor */
+	{ "cte",	"CONTESTEE-APPELLEE"           },	/* Contestee-appellee */
+	{ "ctg",	"CARTOGRAPHER"                 },	/* Cartographer */
+	{ "ctr",	"CONTRACTOR"                   },	/* Contractor */
+	{ "cts",	"CONTESTEE"                    },	/* Contestee */
+	{ "ctt",	"CONTESTEE-APPELLANT"          },	/* Contestee-appellant */
+	{ "cur",	"CURATOR"                      },	/* Curator */
+	{ "cwt",	"COMMENTATOR_FOR_WRITTEN_TEXT" },	/* Commentator for written text */
+	{ "dbp",	"DISTRIBUTION_PLACE"           },	/* Distribution place */
+	{ "degree grantor", "DEGREEGRANTOR"            },
+	{ "dfd",	"DEFENDANT"                    },	/* Defendant */
+	{ "dfe",	"DEFENDANT-APPELLEE"           },	/* Defendant-appellee */
+	{ "dft",	"DEFENDANT-APPELLANT"          },	/* Defendant-appellant */
+	{ "dgg",	"DEGREEGRANTOR"                },	/* Degree granting institution */
+	{ "dgs",	"DEGREE_SUPERVISOR"            },	/* Degree supervisor */
+	{ "dis",	"DISSERTANT"                   },	/* Dissertant */
+	{ "dln",	"DELINEATOR"                   },	/* Delineator */
+	{ "dnc",	"DANCER"                       },	/* Dancer */
+	{ "dnr",	"DONOR"                        },	/* Donor */
+	{ "dpc",	"DEPICTED"                     },	/* Depicted */
+	{ "dpt",	"DEPOSITOR"                    },	/* Depositor */
+	{ "drm",	"DRAFTSMAN"                    }, 	/* Draftsman */
+	{ "drt",	"DIRECTOR"                     }, 	/* Director */
+	{ "dsr",	"DESIGNER"                     }, 	/* Designer */
+	{ "dst",	"DISTRIBUTOR"                  }, 	/* Distributor */
+	{ "dtc",	"DATA_CONTRIBUTOR"             }, 	/* Data contributor */
+	{ "dte",	"DEDICATEE"                    }, 	/* Dedicatee */
+	{ "dtm",	"DATA_MANAGER"                 }, 	/* Data manager */
+	{ "dto",	"DEDICATOR"                    }, 	/* Dedicator */
+	{ "dub",	"AUTHOR"                       },	/* Dubious author */
+	{ "edc",	"EDITOR"                       }, 	/* Editor of compilation */
+	{ "edm",	"EDITOR"                       },	/* Editor of moving image work */
+	{ "edt",	"EDITOR"                       },	/* Editor */
+	{ "egr",	"ENGRAVER"                     }, 	/* Engraver */
+	{ "elg",	"ELECTRICIAN" 	               },	/* Electrician */
+	{ "elt",	"ELECTROTYPER"                 },	/* Electrotyper */
+	{ "eng",	"ENGINEER"                     }, 	/* Engineer */
+	{ "enj",	"ENACTING_JURISICTION"         }, 	/* Enacting jurisdiction */
+	{ "etr",	"ETCHER"                       }, 	/* Etcher */
+	{ "evp",	"EVENT_PLACE"                  }, 	/* Event place */
+	{ "exp",	"EXPERT"                       }, 	/* Expert */
+	{ "fac",	"FACSIMILIST"                  }, 	/* Facsimilist */
+	{ "fds",	"FILM_DISTRIBUTOR"             }, 	/* Film distributor */
+	{ "fld",	"FIELD_DIRECTOR"               }, 	/* Field director */
+	{ "flm",	"FILM_EDITOR"                  }, 	/* Film editor */
+	{ "fmd",	"FILM_DIRECTOR"                }, 	/* Film director */
+	{ "fmk",	"FILMMAKER"                    }, 	/* Filmmaker */
+	{ "fmo",	"FORMER_OWNER"                 }, 	/* Former owner */
+	{ "fmp",	"FILM_PRODUCER"                }, 	/* Film producer */
+	{ "fnd",	"FUNDER"                       }, 	/* Funder */
+	{ "fpy",	"FIRST_PARTY"                  }, 	/* First party */
+	{ "frg",	"FORGER"                       }, 	/* Forger */
+	{ "gis",	"GEOGRAPHIC_INFORMATON_SPECIALIST" }, 	/* Geographic information specialist */
+	{ "grt",	"GRAPHIC_TECHNICIAN"           }, 	/* Graphic technician */
+	{ "his",	"HOST_INSTITUTION"             }, 	/* Host institution */
+	{ "hnr",	"HONOREE"                      }, 	/* Honoree */
+	{ "hst",	"HOST"                         }, 	/* Host */
+	{ "ill",	"ILLUSTRATOR"                  }, 	/* Illustrator */
+	{ "ilu",	"ILLUMINATOR"                  }, 	/* Illuminator */
+	{ "ins",	"INSCRIBER"                    }, 	/* Inscriber */
+	{ "inv",	"INVENTOR"                     }, 	/* Inventor */
+	{ "isb",	"ISSUING_BODY"                 }, 	/* Issuing body */
+	{ "itr",	"INSTRUMENTALIST"              }, 	/* Instrumentalist */
+	{ "ive",	"INTERVIEWEE"                  }, 	/* Interviewee */
+	{ "ivr",	"INTERVIEWER"                  }, 	/* Interviewer */
+	{ "jud",	"JUDGE"                        }, 	/* Judge */
+	{ "jug",	"JURISDICTION_GOVERNED"        }, 	/* Jurisdiction governed */
+	{ "lbr",	"LABORATORY"                   }, 	/* Laboratory */
+	{ "lbt",	"LIBRETTIST"                   }, 	/* Librettist */
+	{ "ldr",	"LABORATORY_DIRECTORY"         }, 	/* Laboratory director */
+	{ "led",	"LEAD"                         }, 	/* Lead */
+	{ "lee",	"LIBELEE-APPELLEE"             }, 	/* Libelee-appellee */
+	{ "lel",	"LIBELEE"                      }, 	/* Libelee */
+	{ "len",	"LENDER"                       }, 	/* Lender */
+	{ "let",	"LIBELEE-APPELLANT"            }, 	/* Libelee-appellant */
+	{ "lgd",	"LIGHTING_DESIGNER"            }, 	/* Lighting designer */
+	{ "lie",	"LIBELANT-APPELLEE"            }, 	/* Libelant-appellee */
+	{ "lil",	"LIBELANT"                     }, 	/* Libelant */
+	{ "lit",	"LIBELANT-APPELLANT"           }, 	/* Libelant-appellant */
+	{ "lsa",	"LANDSCAPE_ARCHITECT"          }, 	/* Landscape architect */
+	{ "lse",	"LICENSEE"                     }, 	/* Licensee */
+	{ "lso",	"LICENSOR"                     }, 	/* Licensor */
+	{ "ltg",	"LITHOGRAPHER"                 }, 	/* Lithographer */
+	{ "lyr",	"LYRICIST"                     }, 	/* Lyricist */
+	{ "mcp",	"MUSIC_COPYIST"                }, 	/* Music copyist */
+	{ "mdc",	"METADATA_CONTACT"             }, 	/* Metadata contact */
+	{ "med",	"MEDIUM"                       }, 	/* Medium */
+	{ "mfp",	"MANUFACTURE_PLACE"            }, 	/* Manufacture place */
+	{ "mfr",	"MANUFACTURER"                 }, 	/* Manufacturer */
+	{ "mod",	"MODERATOR"                    }, 	/* Moderator */
+	{ "mon",	"THESIS_EXAMINER"              }, 	/* Monitor */
+	{ "mrb",	"MARBLER"                      }, 	/* Marbler */
+	{ "mrk",	"EDITOR"                       }, 	/* Markup editor */
+	{ "msd",	"MUSICAL_DIRECTOR"             }, 	/* Musical director */
+	{ "mte",	"METAL-ENGRAVER"               }, 	/* Metal-engraver */
+	{ "mtk",	"MINUTE_TAKER"                 },       /* Minute taker */
+	{ "mus",	"MUSICIAN"                     }, 	/* Musician */
+	{ "nrt",	"NARRATOR"                     }, 	/* Narrator */
+	{ "opn",	"THESIS_OPPONENT"              }, 	/* Opponent */
+	{ "org",	"ORIGINATOR"                   }, 	/* Originator */
+	{ "organizer of meeting", "ORGANIZER"          },
+	{ "orm",	"ORGANIZER"                    }, 	/* Organizer */
+	{ "osp",	"ONSCREEN_PRESENTER"           }, 	/* Onscreen presenter */
+	{ "oth",	"THESIS_OTHER"                 }, 	/* Other */
+	{ "own",	"OWNER"                        }, 	/* Owner */
+	{ "pan",	"PANELIST"                     }, 	/* Panelist */
+	{ "pat",	"PATRON"                       }, 	/* Patron */
+	{ "patent holder", "ASSIGNEE"                  },
+	{ "pbd",	"PUBLISHING_DIRECTOR"          }, 	/* Publishing director */
+	{ "pbl",	"PUBLISHER"                    }, 	/* Publisher */
+	{ "pdr",	"PROJECT_DIRECTOR"             },	/* Project director */
+	{ "pfr",	"PROOFREADER"                  }, 	/* Proofreader */
+	{ "pht",	"PHOTOGRAPHER"                 }, 	/* Photographer */
+	{ "plt",	"PLATEMAKER"                   }, 	/* Platemaker */
+	{ "pma",	"PERMITTING_AGENCY"            }, 	/* Permitting agency */
+	{ "pmn",	"PRODUCTION_MANAGER"           }, 	/* Production manager */
+	{ "pop",	"PRINTER_OF_PLATES"            }, 	/* Printer of plates */
+	{ "ppm",	"PAPERMAKER"                   }, 	/* Papermaker */
+	{ "ppt",	"PUPPETEER"                    }, 	/* Puppeteer */
+	{ "pra",	"PRAESES"                      }, 	/* Praeses */
+	{ "prc",	"PROCESS_CONTRACT"             }, 	/* Process contact */
+	{ "prd",	"PRODUCTION_PERSONNEL"         }, 	/* Production personnel */
+	{ "pre",	"PRESENTER"                    },	/* Presenter */
+	{ "prf",	"PERFORMER"                    }, 	/* Performer */
+	{ "prg",	"AUTHOR"                       }, 	/* Programmer */
+	{ "prm",	"PRINTMAKER"                   }, 	/* Printmaker */
+	{ "prn",	"PRODUCTION_COMPANY"           }, 	/* Production company */
+	{ "pro",	"PRODUCER"                     }, 	/* Producer */
+	{ "prp",	"PRODUCTION_PLACE"             }, 	/* Production place */
+	{ "prs",	"PRODUCTION_DESIGNER"          }, 	/* Production designer */
+	{ "prt",	"PRINTER"                      }, 	/* Printer */
+	{ "prv",	"PROVIDER"                     }, 	/* Provider */
+	{ "pta",	"PATENT_APPLICANT"             }, 	/* Patent applicant */
+	{ "pte",	"PLAINTIFF-APPELLEE"           }, 	/* Plaintiff-appellee */
+	{ "ptf",	"PLAINTIFF"                    }, 	/* Plaintiff */
+	{ "pth",	"ASSIGNEE"                     }, 	/* Patent holder */
+	{ "ptt",	"PLAINTIFF-APPELLANT"          }, 	/* Plaintiff-appellant */
+	{ "pup",	"PUBLICATION_PLACE"            }, 	/* Publication place */
+	{ "rbr",	"RUBRICATOR"                   }, 	/* Rubricator */
+	{ "rcd",	"RECORDIST"                    }, 	/* Recordist */
+	{ "rce",	"RECORDING_ENGINEER"           }, 	/* Recording engineer */
+	{ "rcp",	"ADDRESSEE"                    }, 	/* Addressee */
+	{ "rdd",	"RADIO_DIRECTOR"               }, 	/* Radio director */
+	{ "red",	"REDAKTOR"                     }, 	/* Redaktor */
+	{ "ren",	"RENDERER"                     }, 	/* Renderer */
+	{ "res",	"RESEARCHER"                   }, 	/* Researcher */
+	{ "rev",	"REVIEWER"                     }, 	/* Reviewer */
+	{ "rpc",	"RADIO_PRODUCER"               }, 	/* Radio producer */
+	{ "rps",	"REPOSITORY"                   }, 	/* Repository */
+	{ "rpt",	"REPORTER"                     }, 	/* Reporter */
+	{ "rpy",	"RESPONSIBLE_PARTY"            }, 	/* Responsible party */
+	{ "rse",	"RESPONDENT-APPELLEE"          }, 	/* Respondent-appellee */
+	{ "rsg",	"RESTAGER"                     }, 	/* Restager */
+	{ "rsp",	"RESPONDENT"                   }, 	/* Respondent */
+	{ "rsr",	"RESTORATIONIST"               }, 	/* Restorationist */
+	{ "rst",	"RESPONDENT-APPELLANT"         }, 	/* Respondent-appellant */
+	{ "rth",	"RESEARCH_TEAM_HEAD"           }, 	/* Research team head */
+	{ "rtm",	"RESEARCH_TEAM_MEMBER"         }, 	/* Research team member */
+	{ "sad",	"SCIENTIFIC_ADVISOR"           }, 	/* Scientific advisor */
+	{ "sce",	"SCENARIST"                    }, 	/* Scenarist */
+	{ "scl",	"SCULPTOR"                     }, 	/* Sculptor */
+	{ "scr",	"SCRIBE"                       }, 	/* Scribe */
+	{ "sds",	"SOUND_DESIGNER"               }, 	/* Sound designer */
+	{ "sec",	"SECRETARY"                    }, 	/* Secretary */
+	{ "sgd",	"STAGE_DIRECTOR"               }, 	/* Stage director */
+	{ "sgn",	"SIGNER"                       }, 	/* Signer */
+	{ "sht",	"SUPPORTING_HOST"              }, 	/* Supporting host */
+	{ "sll",	"SELLER"                       }, 	/* Seller */
+	{ "sng",	"SINGER"                       }, 	/* Singer */
+	{ "spk",	"SPEAKER"                      }, 	/* Speaker */
+	{ "spn",	"SPONSOR"                      }, 	/* Sponsor */
+	{ "spy",	"SECOND_PARTY"                 }, 	/* Second party */
+	{ "srv",	"SURVEYOR"                     }, 	/* Surveyor */
+	{ "std",	"SET_DESIGNER"                 },	/* Set designer */
+	{ "stg",	"SETTING"                      },	/* Setting */
+	{ "stl",	"STORYTELLER"                  },	/* Storyteller */
+	{ "stm",	"STAGE_MANAGER"                },	/* Stage manager */
+	{ "stn",	"STANDARDS_BODY"               },	/* Standards body */
+	{ "str",	"STEREOTYPER"                  },	/* Stereotyper */
+	{ "tcd",	"TECHNICAL_DIRECTOR"           },	/* Technical director */
+	{ "tch",	"TEACHER"                      },	/* Teacher */
+	{ "ths",	"THESIS_ADVISOR"               },	/* Thesis advisor */
+	{ "tld",	"TELEVISION_DIRECTOR"          },	/* Television director */
+	{ "tlp",	"TELEVISION_PRODUCER"          },	/* Television producer */
+	{ "trc",	"TRANSCRIBER"                  },	/* Transcriber */
+	{ "trl",	"TRANSLATOR"                   },	/* Translator */
+	{ "tyd",	"TYPE_DIRECTOR"                }, 	/* Type designer */
+	{ "tyg",	"TYPOGRAPHER"                  }, 	/* Typographer */
+	{ "uvp",	"UNIVERSITY_PLACE"             }, 	/* University place */
+	{ "vac",	"VOICE_ACTOR"                  }, 	/* Voice actor */
+	{ "vdg",	"VIDEOGRAPHER"                 }, 	/* Videographer */
+	{ "voc",	"VOCALIST"                     }, 	/* Vocalist */
+	{ "wac",	"AUTHOR"                       }, 	/* Writer of added commentary */
+	{ "wal",	"AUTHOR"                       }, 	/* Writer of added lyrics */
+	{ "wam",	"AUTHOR"                       }, 	/* Writer of accompanying material */
+	{ "wat",	"AUTHOR"                       }, 	/* Writer of added text */
+	{ "wdc",	"WOODCUTTER"                   }, 	/* Woodcutter */
+	{ "wde",	"WOOD_ENGRAVER"                }, 	/* Wood engraver */
+	{ "win",	"AUTHOR"                       }, 	/* Writer of introduction */
+	{ "wit",	"WITNESS"                      }, 	/* Witness */
+	{ "wpr",	"AUTHOR"                       }, 	/* Writer of preface */
+	{ "wst",	"AUTHOR"                       }, 	/* Writer of supplementary textual content */
+};
+
+static const int nrealtors = sizeof( relators ) / sizeof( relators[0] );
+
+char *
+marc_convertrole( const char *query )
+{
+	int i;
+
+	for ( i=0; i<nrealtors; ++i ) {
+		if ( !strcasecmp( query, relators[i].abbreviation ) )
+			return relators[i].internal_name;
+	}
+	return NULL;
+}
 
 static int
 position_in_list( const char *list[], int nlist, const char *query )
diff --git a/bibutils/marc_auth.h b/bibutils/marc_auth.h
--- a/bibutils/marc_auth.h
+++ b/bibutils/marc_auth.h
@@ -15,5 +15,6 @@
 int is_marc_genre( const char *query );
 int marc_findresource( const char *query );
 int is_marc_resource( const char *query );
+char *marc_convertrole( const char *query );
 
 #endif
diff --git a/bibutils/modsin.c b/bibutils/modsin.c
--- a/bibutils/modsin.c
+++ b/bibutils/modsin.c
@@ -292,56 +292,40 @@
 static int
 modsin_marcrole_convert( str *s, char *suffix, str *out )
 {
-	convert roles[] = {
-		{ "author",              "AUTHOR",        0, 0 },
-		{ "aut",                 "AUTHOR",        0, 0 },
-		{ "aud",                 "AUTHOR",        0, 0 },
-		{ "aui",                 "AUTHOR",        0, 0 },
-		{ "aus",                 "AUTHOR",        0, 0 },
-		{ "creator",             "AUTHOR",        0, 0 },
-		{ "cre",                 "AUTHOR",        0, 0 },
-		{ "editor",              "EDITOR",        0, 0 },
-		{ "edt",                 "EDITOR",        0, 0 },
-		{ "degree grantor",      "DEGREEGRANTOR", 0, 0 },
-		{ "dgg",                 "DEGREEGRANTOR", 0, 0 },
-		{ "organizer of meeting","ORGANIZER",     0, 0 },
-		{ "orm",                 "ORGANIZER",     0, 0 },
-		{ "patent holder",       "ASSIGNEE",      0, 0 },
-		{ "pth",                 "ASSIGNEE",      0, 0 }
-	};
-	int nroles = sizeof( roles ) / sizeof( roles[0] );
-	int i, nmismatch, n = -1, status = BIBL_OK;
-	char *p, *q;
+	int i, sstatus, status = BIBL_OK;
+	slist tokens;
+	char *p;
 
-	if ( s->len == 0 ) {
-		/* ...default to author on an empty string */
-		n = 0;
-	} else {
-		/* ...find first match in '|'-separated list */
-		for ( i=0; i<nroles && n==-1; ++i ) {
-			p = s->data;
-			while ( *p ) {
-				q = roles[i].mods;
-				nmismatch = 0;
-				while ( *p && *p!='|' && nmismatch == 0) {
-					if ( toupper( (unsigned char)*p ) != toupper( (unsigned char)*q ) )
-						nmismatch++;
-					p++;
-					q++;
-				}
-				if ( !nmismatch && !(*(q++))) n = i;
-				if ( *p=='|' ) p++;
+	slist_init( &tokens );
+
+	/* ...default to author on an empty string */
+	if ( str_is_empty( s ) ) {
+		str_strcpyc( out, "AUTHOR" );
+	}
+
+	else {
+		sstatus = slist_tokenize( &tokens, s, "|", 1 );
+		if ( sstatus!=SLIST_OK ) {
+			status = BIBL_ERR_MEMERR;
+			goto done;
+		}
+		/* ...take first match */
+		for ( i=0; i<tokens.n; ++i ) {
+			p = marc_convertrole( slist_cstr( &tokens, i ) );
+			if ( p ) {
+				str_strcpyc( out, p );
+				goto done;
 			}
 		}
+		/* ...otherwise just copy input */
+		str_strcpy( out, slist_str( &tokens, 0 ) );
+		str_toupper( out );
 	}
 
-	if ( n!=-1 ) {
-		str_strcpyc( out, roles[n].internal );
-		if ( suffix ) str_strcatc( out, suffix );
-	} else {
-		str_strcpy( out, s );
-	}
-	if ( str_memerr( out ) ) status = BIBL_ERR_MEMERR;
+done:
+	if ( suffix ) str_strcatc( out, suffix );
+	slist_free( &tokens );
+	if ( str_memerr( out ) ) return BIBL_ERR_MEMERR;
 	return status;
 }
 
@@ -718,6 +702,22 @@
 	if ( !xml_has_value( node ) ) return BIBL_OK;
 
 	d = xml_value_cstr( node );
+
+	/* ...handle special genres in KTH DivA */
+	if ( !strcmp( d, "conferenceProceedings" ) || !strcmp( d, "conferencePaper" ) )
+		d = "conference publication";
+	else if ( !strcmp( d, "artisticOutput" ) || !strcmp( d, "other" ) )
+		d = "miscellaneous";
+	else if ( !strcmp( d, "studentThesis" ) )
+		d = "thesis";
+	else if ( !strcmp( d, "monographDoctoralThesis" ) )
+		d = "Ph.D. thesis";
+	else if ( !strcmp( d, "comprehensiveDoctoralThesis" ) )
+		d = "Ph.D. thesis";
+	else if ( !strcmp( d, "monographLicentiateThesis" ) )
+		d = "Licentiate thesis";
+	else if ( !strcmp( d, "comprehensiveLicentiateThesis" ) )
+		d = "Licentiate thesis";
 
 	if ( is_marc_genre( d ) )
 		fstatus = fields_add( info, "GENRE:MARC", d, level );
diff --git a/bibutils/modsout.c b/bibutils/modsout.c
--- a/bibutils/modsout.c
+++ b/bibutils/modsout.c
@@ -302,7 +302,7 @@
 	  { "patent holder",                       "ASSIGNEE",        0, MARC_AUTHORITY },
 	  { "performer",                           "PERFORMER",       0, MARC_AUTHORITY },
 	  { "producer",                            "PRODUCER",        0, MARC_AUTHORITY },
-	  { "recipient",                           "RECIPIENT",       0, MARC_AUTHORITY },
+	  { "addressee",                           "ADDRESSEE",       0, MARC_AUTHORITY },
 	  { "redactor",                            "REDACTOR",        0, MARC_AUTHORITY },
 	  { "reporter",                            "REPORTER",        0, MARC_AUTHORITY },
 	  { "sponsor",                             "SPONSOR",         0, MARC_AUTHORITY },
diff --git a/bibutils/nbibtypes.c b/bibutils/nbibtypes.c
--- a/bibutils/nbibtypes.c
+++ b/bibutils/nbibtypes.c
@@ -38,6 +38,7 @@
 	{ "JT",     "TITLE",              SIMPLE, LEVEL_HOST }, /* Journal title */
 	{ "JID",    "",                   SKIP,   LEVEL_HOST }, /* Journal ID? */
 	{ "SB",     "",                   SKIP,   LEVEL_MAIN },
+	{ "MH",     "KEYWORD",            SIMPLE, LEVEL_MAIN },
 	{ "PMC",    "PMC",                SIMPLE, LEVEL_MAIN },
 	{ "OID",    "",                   SKIP,   LEVEL_MAIN },
 	{ "EDAT",   "",                   SKIP,   LEVEL_MAIN },
diff --git a/bibutils/reftypes.h b/bibutils/reftypes.h
--- a/bibutils/reftypes.h
+++ b/bibutils/reftypes.h
@@ -18,30 +18,30 @@
 #define SKIP            (2)
 
 /* Reftypes to be handled by converters */
-#define SIMPLE          (2)
-#define TYPE            (3)
-#define PERSON          (4)
-#define DATE            (5)
-#define PAGES           (6)
-#define SERIALNO        (7)
-#define TITLE           (8)
-#define NOTES           (9)
-#define DOI             (10)
-#define HOWPUBLISHED    (11)
-#define LINKEDFILE      (12)
-#define KEYWORD         (13)
-#define URL             (14)
-#define GENRE           (15)
-#define BT_SENTE        (16) /* Bibtex 'Sente' */
-#define BT_EPRINT       (17) /* Bibtex 'Eprint' */
-#define BT_ORG          (18) /* Bibtex Organization */
-#define BLT_THESIS_TYPE (19) /* Biblatex Thesis Type */
-#define BLT_SCHOOL      (20) /* Biblatex School */
-#define BLT_EDITOR      (21) /* Biblatex Editor */
-#define BLT_SUBTYPE     (22) /* Biblatex entrysubtype */
-#define BLT_SKIP        (23) /* Biblatex Skip Entry */
-#define EPRINT          (24)
-#define NUM_REFTYPES    (25)
+#define SIMPLE          (3)
+#define TYPE            (4)
+#define PERSON          (5)
+#define DATE            (6)
+#define PAGES           (7)
+#define SERIALNO        (8)
+#define TITLE           (9)
+#define NOTES           (10)
+#define DOI             (11)
+#define HOWPUBLISHED    (12)
+#define LINKEDFILE      (13)
+#define KEYWORD         (14)
+#define URL             (15)
+#define GENRE           (16)
+#define BT_SENTE        (17) /* Bibtex 'Sente' */
+#define BT_EPRINT       (18) /* Bibtex 'Eprint' */
+#define BT_ORG          (19) /* Bibtex Organization */
+#define BLT_THESIS_TYPE (20) /* Biblatex Thesis Type */
+#define BLT_SCHOOL      (21) /* Biblatex School */
+#define BLT_EDITOR      (22) /* Biblatex Editor */
+#define BLT_SUBTYPE     (23) /* Biblatex entrysubtype */
+#define BLT_SKIP        (24) /* Biblatex Skip Entry */
+#define EPRINT          (25)
+#define NUM_REFTYPES    (26)
 
 typedef struct {
 	char *oldstr;
diff --git a/bibutils/risin.c b/bibutils/risin.c
--- a/bibutils/risin.c
+++ b/bibutils/risin.c
@@ -489,7 +489,8 @@
 		     !strcasecmp(value,"Masters Thesis")||
 		     !strcasecmp(value,"Diploma Thesis")||
 		     !strcasecmp(value,"Doctoral Thesis")||
-		     !strcasecmp(value,"Habilitation Thesis")) {
+		     !strcasecmp(value,"Habilitation Thesis")||
+		     !strcasecmp(value,"Licentiate Thesis")) {
 			fstatus = fields_add( bibout, "GENRE:BIBUTILS", value, 0 );
 			if ( fstatus!=FIELDS_OK ) return BIBL_ERR_MEMERR;
 		}
diff --git a/bibutils/risout.c b/bibutils/risout.c
--- a/bibutils/risout.c
+++ b/bibutils/risout.c
@@ -69,6 +69,7 @@
 	TYPE_REPORT,             /* report */
 	TYPE_STATUTE,            /* statute */
 	TYPE_THESIS,             /* thesis */
+	TYPE_LICENTIATETHESIS,   /* thesis */
 	TYPE_MASTERSTHESIS,      /* thesis */
 	TYPE_PHDTHESIS,          /* thesis */
 	TYPE_DIPLOMATHESIS,      /* thesis */
@@ -119,6 +120,7 @@
 		[ TYPE_REPORT             ] = "TYPE_REPORT",
 		[ TYPE_STATUTE            ] = "TYPE_STATUTE",
 		[ TYPE_THESIS             ] = "TYPE_THESIS",
+		[ TYPE_LICENTIATETHESIS   ] = "TYPE_LICENTIATETHESIS",
 		[ TYPE_MASTERSTHESIS      ] = "TYPE_MASTERSTHESIS",
 		[ TYPE_PHDTHESIS          ] = "TYPE_PHDTHESIS",
 		[ TYPE_DIPLOMATHESIS      ] = "TYPE_DIPLOMATHESIS",
@@ -175,6 +177,7 @@
 		{ "legal case and case notes", TYPE_CASE },
 		{ "book chapter",              TYPE_INBOOK },
 		{ "Ph.D. thesis",              TYPE_PHDTHESIS },
+		{ "Licentiate thesis",         TYPE_LICENTIATETHESIS },
 		{ "Masters thesis",            TYPE_MASTERSTHESIS },
 		{ "Diploma thesis",            TYPE_DIPLOMATHESIS },
 		{ "Doctoral thesis",           TYPE_DOCTORALTHESIS },
@@ -184,6 +187,7 @@
 		{ "abstract or summary",       TYPE_ABSTRACT },
 		{ "patent",                    TYPE_PATENT },
 		{ "unpublished",               TYPE_UNPUBLISHED },
+		{ "manuscript",                TYPE_UNPUBLISHED },
 		{ "map",                       TYPE_MAP },
 	};
 	int nmatch_genres = sizeof( match_genres ) / sizeof( match_genres[0] );
@@ -544,6 +548,11 @@
 
 	else if ( type==TYPE_HABILITATIONTHESIS ) {
 		fstatus = fields_add( out, "U1", "Habilitation thesis", LEVEL_MAIN );
+		if ( fstatus!=FIELDS_OK ) *status = BIBL_ERR_MEMERR;
+	}
+
+	else if ( type==TYPE_LICENTIATETHESIS ) {
+		fstatus = fields_add( out, "U1", "Licentiate thesis", LEVEL_MAIN );
 		if ( fstatus!=FIELDS_OK ) *status = BIBL_ERR_MEMERR;
 	}
 }
diff --git a/bibutils/ristypes.c b/bibutils/ristypes.c
--- a/bibutils/ristypes.c
+++ b/bibutils/ristypes.c
@@ -793,7 +793,7 @@
 
 static lookups communication[] = {
 	{ "A1", "AUTHOR",       PERSON,  LEVEL_MAIN },   /* Deprecated? */
-	{ "A2", "RECIPIENT",    PERSON,  LEVEL_MAIN },   /* SPECIAL */
+	{ "A2", "ADDRESSEE",    PERSON,  LEVEL_MAIN },   /* SPECIAL */
 	{ "A3", "EDITOR",       PERSON,  LEVEL_SERIES }, /* 'Tertiary' Author - Series editor */
 	{ "A4", "AUTHOR",       PERSON,  LEVEL_SERIES }, /* 'Subsidiary' Author */
 	{ "AB", "ABSTRACT",     SIMPLE,  LEVEL_MAIN },   /* Abstract */
diff --git a/bibutils/str.c b/bibutils/str.c
--- a/bibutils/str.c
+++ b/bibutils/str.c
@@ -1038,3 +1038,10 @@
 	if ( !s || s->len==0 ) return 1;
 	return 0;
 }
+
+unsigned long
+str_strlen( str *s )
+{
+	if ( !s ) return 0;
+	else return s->len;
+}
diff --git a/bibutils/str.h b/bibutils/str.h
--- a/bibutils/str.h
+++ b/bibutils/str.h
@@ -101,6 +101,8 @@
 
 int  str_memerr( str *s );
 
+unsigned long str_strlen( str *s );
+
 int  str_has_value( str *s );
 int  str_is_empty( str *s );
 
diff --git a/bibutils/wordout.c b/bibutils/wordout.c
--- a/bibutils/wordout.c
+++ b/bibutils/wordout.c
@@ -428,7 +428,7 @@
 {
 	char *authors[] = { "AUTHOR", "WRITER", "ASSIGNEE", "ARTIST",
 		"CARTOGRAPHER", "INVENTOR", "ORGANIZER", "DIRECTOR",
-		"PERFORMER", "REPORTER", "TRANSLATOR", "RECIPIENT",
+		"PERFORMER", "REPORTER", "TRANSLATOR", "ADDRESSEE",
 		"2ND_AUTHOR", "3RD_AUTHOR", "SUB_AUTHOR", "COMMITTEE",
 		"COURT", "LEGISLATIVEBODY" };
 	int nauthors = sizeof( authors ) / sizeof( authors[0] );
diff --git a/hs-bibutils.cabal b/hs-bibutils.cabal
--- a/hs-bibutils.cabal
+++ b/hs-bibutils.cabal
@@ -1,5 +1,5 @@
 name:               hs-bibutils
-version:            6.4.0.0
+version:            6.5.0.0
 homepage:           https://github.com/wilx/hs-bibutils
 
 synopsis:           Haskell bindings to bibutils, the bibliography
