You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After files are scored, **ctxeng** parses static ``import`` / ``from … import`` statements in each discovered ``.py`` file, resolves **relative imports** from the file’s location, and can **pull in imported modules** from the same collection set before the token budget is applied.
174
+
175
+
-**Default:** one hop (`import_graph_depth=1`), relevance for added files = parent score × **0.7**
176
+
-**Edges only** to files already in the current discovery set (filesystem / git / explicit list)
177
+
- Stdlib and third-party imports are ignored (no file under your root → no edge)
178
+
179
+
```python
180
+
from ctxeng import ContextEngine, ContextBuilder
181
+
182
+
# Engine: on by default; adjust depth or turn off
183
+
engine = ContextEngine(
184
+
root=".",
185
+
use_import_graph=True,
186
+
import_graph_depth=2,
187
+
)
188
+
189
+
ctx = (
190
+
ContextBuilder(".")
191
+
.for_model("claude-sonnet-4")
192
+
.use_import_graph(depth=2) # follow two hops of local imports
0 commit comments