A dyak was a title of the chief of a structural division of a prikaz. For example, "посольский дьяк" (posolsky dyak) is a dyak of the Posolsky Prikaz (Diplomacy Department). A duma dyak (думный дьяк) was the lowest rank in the Boyar Duma (15-17th centuries).
Outside of the grand princely administration, dyaki were also found in ecclesiastical (episcopal) administrations, particularly in Novgorod the Great. In this sense they may be more broadly defined as secretaries or clerks. According to the Life of Archbishop Iona of Novgorod (r. 1458-1470), although he was a poor orphan, the woman who raised him hired a dyak to teach him reading and writing. Chronicle sources also indicate that Archbishop Feofil (r. 1470-1480) had his dyak write up a charter recognizing Grand Prince Ivan III's powers following the grand prince's seizure of the city in 1478.
After the Muscovite take-over, the office of dyak continued as one of the more important administrators of the House of Holy Wisdom, as the archiepiscopal (and later metropolitan) administration in Novgorod the Great was known. The Dvortsovyi Dyak essentially ran the financial and administrative affairs of the archbishops and metropolitans (they were so important that Boris Grekov wrote that one could not brew kvas in the city without his permission.) This, however, was after the Muscovite conquest, and the administrative structure of the House of Holy Wisdom had been reorganized along the lines of the grand princely administration in Moscow. Indeed, when Archbishop Sergei (1483-1484) arrived in Novgorod following his election, he was accompanied by a dyak and a treasurer who were to see that the archiepiscopal administration complied with Muscovite norms.
See "Deacon#Cognates" for other historical terms derived from the Greek diakonos. In particular, the term "dyachok" is constructed in Russian language as a diminutive from "dyak", however it has a completely different meaning.