01
AST Extraction
Your code is parsed into an Abstract Syntax Tree sequence using tree-sitter, normalising variable names to remove stylistic bias.
02
CodeBERT Embeddings
Both raw code and the AST sequence are embedded using microsoft/codebert-base, producing two 768-dimensional vectors.
03
Combined Features
The two vectors are concatenated into a 1,536-dimensional feature vector capturing both syntax and structure.
04
Classification
A Logistic Regression classifier — trained on 984 samples from Claude Haiku, GPT-4o, and Gemini 2.5 — returns a probability score.