To optimize the term hierarchy in the manual e‐government thesaurus, we combine the mainstream knowledge organization technology to form a complete set of ontology automation construction scheme. We build an e‐government knowledge base by using subject words in the Comprehensive E‐government Thesaurus as the term set and encyclopedia text as the corpus. The specific work includes the extraction of semantic features from the bag‐of‐words model, determination of the number of clusters by linear and nonlinear dimensionality reduction, division of terms by spectral clustering, social network analysis to determine the class label, and storing knowledge ontology via OWL. The recall rate of term hierarchy in the ontology is excellent, indicating the ontology has good knowledge extensibility, and also proving the efficiency of the scheme proposed in this work. Besides, the application model of a term hierarchy in information retrieval can show a richer semantic relation than the original thesaurus to guide the retrieval extension of government information resources.