Alexander B. Toth Sr., 88, a retired chief librarian of the Central Intelligence Agency and a former Foreign Service officer who specialized in the collection of foreign publications, died of kidney failure July 11 at his home in Bethesda.

The son of Hungarian immigrants, Mr. Toth was born in Buffalo and grew up in Cleveland.

Mr. Toth graduated from Franklin and Marshall College in Lancaster, Pa., in 1932, and then spent two years studying Hungarian literature at the University of Budapest.

In 1934, he moved to Washington and went to work at the Library of Congress as an assistant selection officer.

In 1945, he joined the State Department and was sent to the U.S. Embassy in London to collect foreign publications.

He was said to be the first embassy attache to receive such an assignment.

In 1948, Mr. Toth joined the CIA. He helped create the document retrieval system that later formed the basis for computerization of the agency's library.

Mr. Toth played a major role in planning the library portion of the CIA's headquarters in Langley, which opened in 1961, and he supervised moving the collection from the agency's downtown Washington offices to the new location. He retired in 1970.

In retirement, Mr. Toth was a volunteer at Arena Stage and with the Meals on Wheels program, and he taught English to immigrants.

Survivors include his wife of 62 years, Gertrude Gray Toth of Bethesda; a son, Alexander B. Toth Jr. of Southport, N.C.; a daughter, Sarah G. Toth of Silver Spring; two sisters; and three grandchildren.