The invention relates to a black-box scene-oriented fine-grained large-
language model pedigree identification method, which comprises the following steps of: constructing a large-
language model black-box detection framework combined with multi-task
domain knowledge and a scientific representative sampling technology, covering a task query
pool of multiple dimensions such as medical
questions and answers, mathematical reasoning and the like, and utilizing a
screening algorithm based on TF-IDF vectorization and KMeans clustering to identify a fine-grained large-
language model pedigree. And extracting most representative detection samples from each task to construct a target query set. Secondly, constructing a task-level knowledge
fingerprint extraction model based on semantic topology and structural fluctuation, and calculating a relative
deviation vector of a response text relative to origin
semantics and a stability statistic (variable coefficient) reflecting the knowledge stability degree by executing multiple independent generation experiments on the model; on this basis, a fine-grained pedigree evolution
traceability fingerprint based on multi-level joint weighted aggregation is realized, the
fingerprint can perform automatic weighting for
vulnerability degrees of different queries in stability
ranking, and weight attenuation and compensation are performed in combination with task-level semantic confidence. And thus, the evolution similarity of the to-be-tested model relative to each candidate
source model is accurately output.