nooa-cli 0.0.7__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- nooa_cli-0.0.7/.gitignore +407 -0
- nooa_cli-0.0.7/PKG-INFO +52 -0
- nooa_cli-0.0.7/README.md +25 -0
- nooa_cli-0.0.7/docs/activity-introspection-design.md +75 -0
- nooa_cli-0.0.7/pyproject.toml +71 -0
- nooa_cli-0.0.7/src/nooa_cli/AGENTS.md +162 -0
- nooa_cli-0.0.7/src/nooa_cli/__init__.py +70 -0
- nooa_cli-0.0.7/src/nooa_cli/__main__.py +8 -0
- nooa_cli-0.0.7/src/nooa_cli/_common.py +45 -0
- nooa_cli-0.0.7/src/nooa_cli/commands/__init__.py +106 -0
- nooa_cli-0.0.7/src/nooa_cli/commands/_otlp_helpers.py +122 -0
- nooa_cli-0.0.7/src/nooa_cli/commands/_template.py +89 -0
- nooa_cli-0.0.7/src/nooa_cli/commands/config.py +356 -0
- nooa_cli-0.0.7/src/nooa_cli/commands/delete_traces.py +63 -0
- nooa_cli-0.0.7/src/nooa_cli/commands/eval.py +68 -0
- nooa_cli-0.0.7/src/nooa_cli/commands/import_harbor.py +512 -0
- nooa_cli-0.0.7/src/nooa_cli/commands/import_traces.py +189 -0
- nooa_cli-0.0.7/src/nooa_cli/commands/start_dev.py +145 -0
- nooa_cli-0.0.7/src/nooa_cli/commands/traces.py +316 -0
- nooa_cli-0.0.7/src/nooa_cli/completion.py +253 -0
- nooa_cli-0.0.7/src/nooa_cli/tools/__init__.py +0 -0
- nooa_cli-0.0.7/src/nooa_cli/tools/_tree_sitter_backend.py +351 -0
- nooa_cli-0.0.7/src/nooa_cli/tools/pyp/__init__.py +71 -0
- nooa_cli-0.0.7/src/nooa_cli/tools/pyp/errors.py +92 -0
- nooa_cli-0.0.7/src/nooa_cli/tools/pyp/sources.py +458 -0
- nooa_cli-0.0.7/src/nooa_cli/tools/pyp/stream.py +527 -0
- nooa_cli-0.0.7/src/nooa_cli/tools/pyp/tests/__init__.py +0 -0
- nooa_cli-0.0.7/src/nooa_cli/tools/pyp/tests/test_pyp.py +394 -0
- nooa_cli-0.0.7/src/nooa_cli/tools/repo_tools.py +902 -0
- nooa_cli-0.0.7/tests/__init__.py +0 -0
- nooa_cli-0.0.7/tests/test_cli_smoke.py +20 -0
|
@@ -0,0 +1,407 @@
|
|
|
1
|
+
# Rust toolchain (installed for nemo_flow PyO3 build)
|
|
2
|
+
.cargo/
|
|
3
|
+
.rustup/
|
|
4
|
+
|
|
5
|
+
# Node.js dependencies (never commit)
|
|
6
|
+
node_modules/
|
|
7
|
+
|
|
8
|
+
# Byte-compiled / optimized / DLL files
|
|
9
|
+
__pycache__/
|
|
10
|
+
*.py[cod]
|
|
11
|
+
*$py.class
|
|
12
|
+
|
|
13
|
+
# C extensions
|
|
14
|
+
*.so
|
|
15
|
+
|
|
16
|
+
# Distribution / packaging
|
|
17
|
+
.Python
|
|
18
|
+
build/
|
|
19
|
+
develop-eggs/
|
|
20
|
+
dist/
|
|
21
|
+
!packages/nemo-oo-agents-viewer/frontend-react/dist/
|
|
22
|
+
!src/nooa/viewer/frontend-react/dist/
|
|
23
|
+
downloads/
|
|
24
|
+
eggs/
|
|
25
|
+
.eggs/
|
|
26
|
+
lib/
|
|
27
|
+
lib64/
|
|
28
|
+
# Exception: allow util/*/lib/ directories (our code, not build artifacts)
|
|
29
|
+
!util/*/lib/
|
|
30
|
+
!util/**/lib/
|
|
31
|
+
parts/
|
|
32
|
+
sdist/
|
|
33
|
+
var/
|
|
34
|
+
wheels/
|
|
35
|
+
pip-wheel-metadata/
|
|
36
|
+
share/python-wheels/
|
|
37
|
+
*.egg-info/
|
|
38
|
+
.installed.cfg
|
|
39
|
+
*.egg
|
|
40
|
+
MANIFEST
|
|
41
|
+
|
|
42
|
+
# PyInstaller
|
|
43
|
+
# Usually these files are written by a python script from a template
|
|
44
|
+
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
|
45
|
+
*.manifest
|
|
46
|
+
*.spec
|
|
47
|
+
|
|
48
|
+
# Installer logs
|
|
49
|
+
pip-log.txt
|
|
50
|
+
pip-delete-this-directory.txt
|
|
51
|
+
|
|
52
|
+
# Unit test / coverage reports
|
|
53
|
+
htmlcov/
|
|
54
|
+
.tox/
|
|
55
|
+
.nox/
|
|
56
|
+
.coverage
|
|
57
|
+
.coverage.*
|
|
58
|
+
.cache
|
|
59
|
+
nosetests.xml
|
|
60
|
+
coverage.xml
|
|
61
|
+
*.cover
|
|
62
|
+
*.py,cover
|
|
63
|
+
.hypothesis/
|
|
64
|
+
.pytest_cache/
|
|
65
|
+
|
|
66
|
+
# Translations
|
|
67
|
+
*.mo
|
|
68
|
+
*.pot
|
|
69
|
+
|
|
70
|
+
# Django stuff:
|
|
71
|
+
*.log
|
|
72
|
+
local_settings.py
|
|
73
|
+
db.sqlite3
|
|
74
|
+
db.sqlite3-journal
|
|
75
|
+
|
|
76
|
+
# Flask stuff:
|
|
77
|
+
instance/
|
|
78
|
+
.webassets-cache
|
|
79
|
+
|
|
80
|
+
# Scrapy stuff:
|
|
81
|
+
.scrapy
|
|
82
|
+
|
|
83
|
+
# Sphinx documentation
|
|
84
|
+
docs/_build/
|
|
85
|
+
|
|
86
|
+
# PyBuilder
|
|
87
|
+
target/
|
|
88
|
+
|
|
89
|
+
# Jupyter Notebook
|
|
90
|
+
.ipynb_checkpoints
|
|
91
|
+
|
|
92
|
+
# IPython
|
|
93
|
+
profile_default/
|
|
94
|
+
ipython_config.py
|
|
95
|
+
|
|
96
|
+
# pyenv
|
|
97
|
+
.python-version
|
|
98
|
+
|
|
99
|
+
# pipenv
|
|
100
|
+
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
|
101
|
+
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
|
102
|
+
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
|
103
|
+
# install all needed dependencies.
|
|
104
|
+
#Pipfile.lock
|
|
105
|
+
|
|
106
|
+
# PEP 582; used by e.g. github.com/David-OConnor/pyflow
|
|
107
|
+
__pypackages__/
|
|
108
|
+
|
|
109
|
+
# Celery stuff
|
|
110
|
+
celerybeat-schedule
|
|
111
|
+
celerybeat.pid
|
|
112
|
+
|
|
113
|
+
# SageMath parsed files
|
|
114
|
+
*.sage.py
|
|
115
|
+
|
|
116
|
+
# Environments
|
|
117
|
+
.env
|
|
118
|
+
.env.*
|
|
119
|
+
!.env.example
|
|
120
|
+
!.env.template
|
|
121
|
+
.venv
|
|
122
|
+
.venv-macos
|
|
123
|
+
env/
|
|
124
|
+
venv/
|
|
125
|
+
ENV/
|
|
126
|
+
env.bak/
|
|
127
|
+
venv.bak/
|
|
128
|
+
|
|
129
|
+
# uv cache directory
|
|
130
|
+
.uv-cache/
|
|
131
|
+
|
|
132
|
+
# Spyder project settings
|
|
133
|
+
.spyderproject
|
|
134
|
+
.spyproject
|
|
135
|
+
|
|
136
|
+
# Rope project settings
|
|
137
|
+
.ropeproject
|
|
138
|
+
|
|
139
|
+
# mkdocs documentation
|
|
140
|
+
/site
|
|
141
|
+
|
|
142
|
+
# mypy
|
|
143
|
+
.mypy_cache/
|
|
144
|
+
.dmypy.json
|
|
145
|
+
dmypy.json
|
|
146
|
+
|
|
147
|
+
# Pyre type checker
|
|
148
|
+
.pyre/
|
|
149
|
+
|
|
150
|
+
# IDEs
|
|
151
|
+
.vscode/*
|
|
152
|
+
.vscode-server/*
|
|
153
|
+
.idea/*
|
|
154
|
+
*.swp
|
|
155
|
+
*.swo
|
|
156
|
+
|
|
157
|
+
# OS
|
|
158
|
+
.DS_Store
|
|
159
|
+
Thumbs.db
|
|
160
|
+
|
|
161
|
+
# Temporal
|
|
162
|
+
temporal/
|
|
163
|
+
.temporal/
|
|
164
|
+
|
|
165
|
+
# Custom
|
|
166
|
+
secrets.env
|
|
167
|
+
local_config.yaml
|
|
168
|
+
|
|
169
|
+
# Security: JWT tokens and API keys
|
|
170
|
+
**/test-nvauth.py
|
|
171
|
+
**/debug-auth*.py
|
|
172
|
+
# JWT token patterns (eyJ...)
|
|
173
|
+
eyJ*
|
|
174
|
+
|
|
175
|
+
# Third-party dependencies
|
|
176
|
+
3P/
|
|
177
|
+
3p/
|
|
178
|
+
|
|
179
|
+
# Trash folder for temporary files
|
|
180
|
+
trash/
|
|
181
|
+
|
|
182
|
+
# Tools directory (generated traces) - only root level
|
|
183
|
+
/tools/
|
|
184
|
+
|
|
185
|
+
# Agent trace files and results (root level)
|
|
186
|
+
/trace/
|
|
187
|
+
/traces/
|
|
188
|
+
/results/
|
|
189
|
+
trace*.json
|
|
190
|
+
!trace_viewer_config.json
|
|
191
|
+
/tmp/
|
|
192
|
+
|
|
193
|
+
# NVIDIA OO Agents generated trace and evaluation files (anywhere)
|
|
194
|
+
*.noo-eval.jsonl
|
|
195
|
+
*.006summary.json
|
|
196
|
+
# Exception: Allow trace fixtures for testing/eval
|
|
197
|
+
!evaluation/fixtures/**/*.noo-eval.jsonl
|
|
198
|
+
|
|
199
|
+
# Interface output markdown (experiment results)
|
|
200
|
+
docs/interface_output/
|
|
201
|
+
|
|
202
|
+
# Trace viewer config backups
|
|
203
|
+
**/trace_viewer_config.json.backup
|
|
204
|
+
|
|
205
|
+
# Local config overrides (user-specific, not tracked)
|
|
206
|
+
**/*.local.json
|
|
207
|
+
|
|
208
|
+
# Bridge watchpoint file (runtime job monitoring, not tracked)
|
|
209
|
+
.bridge_watch.json
|
|
210
|
+
|
|
211
|
+
# Slurm job output files (runtime artifacts, not tracked)
|
|
212
|
+
*.err
|
|
213
|
+
*.out
|
|
214
|
+
|
|
215
|
+
# Cursor IDE rules (keep local but don't track)
|
|
216
|
+
.cursorrules
|
|
217
|
+
|
|
218
|
+
# PDFs
|
|
219
|
+
*.pdf
|
|
220
|
+
packages/.venv/
|
|
221
|
+
|
|
222
|
+
# Experimental implementations (on experimental-implementations branch)
|
|
223
|
+
composer-packages/
|
|
224
|
+
gpt-packages/
|
|
225
|
+
trace_tui/
|
|
226
|
+
NEW_AGENT_TUI.md
|
|
227
|
+
RUN_NEW_AGENT_TUI.md
|
|
228
|
+
SETUP_QWEN_TUI.md
|
|
229
|
+
TUI_INTEGRATION_SUMMARY.md
|
|
230
|
+
run-new-tui.sh
|
|
231
|
+
test-tui-debug.py
|
|
232
|
+
test-tui.sh
|
|
233
|
+
scratch/ALIGNMENT_SUMMARY.md
|
|
234
|
+
scratch/DESIGN_ALIGNMENT_REPORT.md
|
|
235
|
+
packages/nemo_oo_agents-core/src/nemo_oo_agents/cli.py
|
|
236
|
+
packages/nemo_oo_agents-tui/src/nemo_oo_agents_tui/cli.py
|
|
237
|
+
|
|
238
|
+
# Prompt optimization experiment results
|
|
239
|
+
util/prompt-optimization/results/*.json
|
|
240
|
+
util/prompt-optimization/results/*.jsonl
|
|
241
|
+
util/prompt-optimization/results/*/*.json
|
|
242
|
+
util/prompt-optimization/results/*/*.jsonl
|
|
243
|
+
util/prompt-optimization/traces/
|
|
244
|
+
util/prompt-optimization/traces_test/
|
|
245
|
+
|
|
246
|
+
# Eval pipeline experiments and data
|
|
247
|
+
util/e2e_optimization/experiments/
|
|
248
|
+
util/e2e_optimization/src/e2e_optimization/examples/**/*.jsonl
|
|
249
|
+
util/e2e_optimization/src/e2e_optimization/examples/**/results/
|
|
250
|
+
# Exception: allow data_*.jsonl (test datasets)
|
|
251
|
+
!util/e2e_optimization/src/e2e_optimization/examples/**/data_*.jsonl
|
|
252
|
+
util/eval_pipeline/experiments/
|
|
253
|
+
|
|
254
|
+
# Experiment test result directories
|
|
255
|
+
experiments/tau_bench_test*/
|
|
256
|
+
experiments/**/results/
|
|
257
|
+
|
|
258
|
+
traces.db
|
|
259
|
+
traces.db-wal
|
|
260
|
+
traces.db-shm
|
|
261
|
+
# Large result files
|
|
262
|
+
experiments/**/results/
|
|
263
|
+
|
|
264
|
+
# Test files
|
|
265
|
+
test_arxiv_fetch.py
|
|
266
|
+
trigger_librarian_fetch.py
|
|
267
|
+
experiments/evaluation-ablations/*.db
|
|
268
|
+
experiments/evaluation-ablations/test_case_*/
|
|
269
|
+
experiments/evaluation-ablations/test.csv
|
|
270
|
+
experiments/evaluation-ablations/test.json
|
|
271
|
+
agents/**/traces/
|
|
272
|
+
|
|
273
|
+
# Claude Code settings (user-specific)
|
|
274
|
+
.claude/settings.json
|
|
275
|
+
|
|
276
|
+
# Claude Code runtime directories (cache, sessions, IDE state, plugins, skills)
|
|
277
|
+
.claude/backups/
|
|
278
|
+
.claude/history.jsonl
|
|
279
|
+
.claude/cache/
|
|
280
|
+
.claude/file-history/
|
|
281
|
+
.claude/ide/
|
|
282
|
+
.claude/plugins/
|
|
283
|
+
.claude/policy-limits.json
|
|
284
|
+
.claude/projects/
|
|
285
|
+
.claude/sessions/
|
|
286
|
+
.claude/shell-snapshots/
|
|
287
|
+
.claude.json
|
|
288
|
+
|
|
289
|
+
# Agent runtime directory
|
|
290
|
+
.agents/
|
|
291
|
+
|
|
292
|
+
# Shell history
|
|
293
|
+
.bash_history
|
|
294
|
+
|
|
295
|
+
# User-level XDG config/local dirs (injected by sandbox/environment)
|
|
296
|
+
.config/
|
|
297
|
+
.local/
|
|
298
|
+
|
|
299
|
+
# Rust toolchain (installed by rustup for nemo-flow build)
|
|
300
|
+
.cargo/
|
|
301
|
+
.rustup/
|
|
302
|
+
|
|
303
|
+
# VS Code Server (remote development runtime)
|
|
304
|
+
.vscode-server/
|
|
305
|
+
|
|
306
|
+
debug_http_logs/
|
|
307
|
+
|
|
308
|
+
# SWE-bench evaluation logs (generated during test runs)
|
|
309
|
+
**/logs/run_evaluation/
|
|
310
|
+
|
|
311
|
+
# Trace analyzer batch results
|
|
312
|
+
**/analysis_batch/
|
|
313
|
+
|
|
314
|
+
# Claude Code local settings (personal, not shared)
|
|
315
|
+
.claude/settings.local.json
|
|
316
|
+
.claude/agents
|
|
317
|
+
|
|
318
|
+
# Claude Code sandbox artifacts (created at runtime, not project files)
|
|
319
|
+
.srt-settings.json
|
|
320
|
+
# Debug handler dumps (written to cwd on SIGUSR2)
|
|
321
|
+
debug_dump_*.txt
|
|
322
|
+
# NeMo OO project directory (libraries, traces, config)
|
|
323
|
+
.nemo_oo/
|
|
324
|
+
.nooa/
|
|
325
|
+
.nemo_oo_agents/
|
|
326
|
+
# Shell config stubs (empty read-only files injected by sandbox)
|
|
327
|
+
.zshrc
|
|
328
|
+
.zprofile
|
|
329
|
+
.bash_profile
|
|
330
|
+
.bashrc
|
|
331
|
+
.profile
|
|
332
|
+
.gitconfig
|
|
333
|
+
.ripgreprc
|
|
334
|
+
.idea
|
|
335
|
+
.vscode
|
|
336
|
+
# Git internal stubs (root-level sandbox artifacts only)
|
|
337
|
+
/HEAD
|
|
338
|
+
/config
|
|
339
|
+
/hooks
|
|
340
|
+
/objects
|
|
341
|
+
/refs
|
|
342
|
+
# pytest temp directories
|
|
343
|
+
pytest-of-*/
|
|
344
|
+
experiments/evaluation-ablations/task_temp/
|
|
345
|
+
|
|
346
|
+
# DABStep experiment outputs (top-level scratch directory)
|
|
347
|
+
/dabstep/
|
|
348
|
+
|
|
349
|
+
# Harbor generated task directories (regenerated via `harbor adapter run`)
|
|
350
|
+
util/harbor/tasks/
|
|
351
|
+
|
|
352
|
+
# OpenSkills workspace files
|
|
353
|
+
.openskills/
|
|
354
|
+
|
|
355
|
+
# Local lockfile
|
|
356
|
+
prpm.lock
|
|
357
|
+
|
|
358
|
+
# Git worktrees
|
|
359
|
+
.worktrees/
|
|
360
|
+
worktrees/
|
|
361
|
+
|
|
362
|
+
# Bridge session ID file — written by slack bridge into each agent worktree root
|
|
363
|
+
.claude_session_id
|
|
364
|
+
|
|
365
|
+
sft_data/**/*.jsonl
|
|
366
|
+
|
|
367
|
+
# Git credentials (must not be committed)
|
|
368
|
+
.git-credentials
|
|
369
|
+
-e
|
|
370
|
+
# Bridge watchpoint file — per-worktree, never committed
|
|
371
|
+
.bridge_watch.json
|
|
372
|
+
|
|
373
|
+
.claude/backups
|
|
374
|
+
.claude/file-history
|
|
375
|
+
.claude/projects
|
|
376
|
+
.claude/shell-snapshots
|
|
377
|
+
.claude/telemetry
|
|
378
|
+
./claude/sessions
|
|
379
|
+
./claude/cache
|
|
380
|
+
./claude/plugins
|
|
381
|
+
|
|
382
|
+
.local/
|
|
383
|
+
.config/
|
|
384
|
+
util/harbor/tasks/terminal_bench/
|
|
385
|
+
|
|
386
|
+
# WTF skills (generated by wtf install-skills)
|
|
387
|
+
.claude/skills/wtf*
|
|
388
|
+
tests/integration/fixtures/*.db
|
|
389
|
+
tests/integration/fixtures/*.lock
|
|
390
|
+
|
|
391
|
+
# Worktree directories
|
|
392
|
+
.wt-*
|
|
393
|
+
|
|
394
|
+
# Throwaway benchmark smoke-test configs
|
|
395
|
+
util/harbor/tb1_opus_smoke.yaml
|
|
396
|
+
util/harbor/tb1_ultra_smoke.yaml
|
|
397
|
+
.claude/scheduled_tasks.lock
|
|
398
|
+
.commit_msg
|
|
399
|
+
|
|
400
|
+
# LoCoMo benchmark data (downloaded on demand, not vendored)
|
|
401
|
+
examples/memory_bench/data/
|
|
402
|
+
|
|
403
|
+
# Local scratch/working files (never commit)
|
|
404
|
+
.scratch/
|
|
405
|
+
|
|
406
|
+
# Claude Code local session dir (never commit)
|
|
407
|
+
.claude/
|
nooa_cli-0.0.7/PKG-INFO
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: nooa-cli
|
|
3
|
+
Version: 0.0.7
|
|
4
|
+
Summary: CLI for nemo-oo-agents (`nooa` command: eval runner, trace viewer, config)
|
|
5
|
+
Project-URL: Homepage, https://github.com/NVIDIA-NeMo/labs-OO-Agents
|
|
6
|
+
Project-URL: Repository, https://github.com/NVIDIA-NeMo/labs-OO-Agents
|
|
7
|
+
Project-URL: Issues, https://github.com/NVIDIA-NeMo/labs-OO-Agents/issues
|
|
8
|
+
License: Apache-2.0
|
|
9
|
+
Requires-Python: <3.14,>=3.12
|
|
10
|
+
Requires-Dist: click>=8.1.0
|
|
11
|
+
Requires-Dist: nooa
|
|
12
|
+
Requires-Dist: pyyaml>=6.0
|
|
13
|
+
Provides-Extra: ast
|
|
14
|
+
Requires-Dist: tree-sitter-go>=0.23.0; extra == 'ast'
|
|
15
|
+
Requires-Dist: tree-sitter-javascript>=0.23.0; extra == 'ast'
|
|
16
|
+
Requires-Dist: tree-sitter-python>=0.23.0; extra == 'ast'
|
|
17
|
+
Requires-Dist: tree-sitter-rust>=0.23.0; extra == 'ast'
|
|
18
|
+
Requires-Dist: tree-sitter-typescript>=0.23.0; extra == 'ast'
|
|
19
|
+
Requires-Dist: tree-sitter>=0.23.0; extra == 'ast'
|
|
20
|
+
Provides-Extra: datascience
|
|
21
|
+
Requires-Dist: numpy>=1.24.0; extra == 'datascience'
|
|
22
|
+
Requires-Dist: pandas>=2.0.0; extra == 'datascience'
|
|
23
|
+
Requires-Dist: plotly>=5.0.0; extra == 'datascience'
|
|
24
|
+
Requires-Dist: scikit-learn>=1.3.0; extra == 'datascience'
|
|
25
|
+
Requires-Dist: scipy>=1.10.0; extra == 'datascience'
|
|
26
|
+
Description-Content-Type: text/markdown
|
|
27
|
+
|
|
28
|
+
# nooa-cli
|
|
29
|
+
|
|
30
|
+
CLI for [nemo-oo-agents](https://github.com/NVIDIA-NeMo/labs-OO-Agents). Ships the `nooa` command with subcommands for running evaluations, browsing traces, and managing config.
|
|
31
|
+
|
|
32
|
+
## Install
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
uv add nooa-cli
|
|
36
|
+
|
|
37
|
+
# ...with numpy/pandas/plotly/scipy/sklearn pre-loaded into the LLM REPL
|
|
38
|
+
uv add "nooa-cli[datascience]"
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
`nooa-cli` automatically pulls in matching `nemo-oo-agents` (the core framework). The `[datascience]` extra adds libraries the LLM can use in REPL-generated code.
|
|
42
|
+
|
|
43
|
+
## Usage
|
|
44
|
+
|
|
45
|
+
```bash
|
|
46
|
+
nooa --help
|
|
47
|
+
nooa start-dev # launch the trace viewer
|
|
48
|
+
nooa eval ... # eval pipeline runner
|
|
49
|
+
nooa traces ... # inspect/manage trace files
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
See the main repo [README](https://github.com/NVIDIA-NeMo/labs-OO-Agents/blob/main/README.md) for the framework documentation.
|
nooa_cli-0.0.7/README.md
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# nooa-cli
|
|
2
|
+
|
|
3
|
+
CLI for [nemo-oo-agents](https://github.com/NVIDIA-NeMo/labs-OO-Agents). Ships the `nooa` command with subcommands for running evaluations, browsing traces, and managing config.
|
|
4
|
+
|
|
5
|
+
## Install
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
uv add nooa-cli
|
|
9
|
+
|
|
10
|
+
# ...with numpy/pandas/plotly/scipy/sklearn pre-loaded into the LLM REPL
|
|
11
|
+
uv add "nooa-cli[datascience]"
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
`nooa-cli` automatically pulls in matching `nemo-oo-agents` (the core framework). The `[datascience]` extra adds libraries the LLM can use in REPL-generated code.
|
|
15
|
+
|
|
16
|
+
## Usage
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
nooa --help
|
|
20
|
+
nooa start-dev # launch the trace viewer
|
|
21
|
+
nooa eval ... # eval pipeline runner
|
|
22
|
+
nooa traces ... # inspect/manage trace files
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
See the main repo [README](https://github.com/NVIDIA-NeMo/labs-OO-Agents/blob/main/README.md) for the framework documentation.
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
# Can the TUI report "where the agent is stopped" via sys.monitoring?
|
|
2
|
+
|
|
3
|
+
Short answer: **`sys.monitoring` is the wrong tool for this, and you don't need it.**
|
|
4
|
+
A point-in-time "where is the agent right now" probe is answered cheaply and
|
|
5
|
+
safely by `sys._current_frames()` + asyncio task introspection, with **zero**
|
|
6
|
+
changes to the core framework.
|
|
7
|
+
|
|
8
|
+
## How the TUI and agent actually run (verified)
|
|
9
|
+
|
|
10
|
+
`tui_application.py::_ensure_agent_loop` spins up a **dedicated asyncio loop on
|
|
11
|
+
its own daemon thread** (`nemo-tui-agent-loop`) via `loop.run_forever()`. The
|
|
12
|
+
agent's `handle()` runs as a task on that loop. prompt_toolkit / the UI runs on
|
|
13
|
+
`MainThread`. So:
|
|
14
|
+
|
|
15
|
+
- Agent work = one coroutine (`TUIAgent.handle`) on the agent loop, agent thread.
|
|
16
|
+
- The "asker" (a slash command / keybinding) originates on the UI thread.
|
|
17
|
+
|
|
18
|
+
## Why sys.monitoring doesn't fit
|
|
19
|
+
|
|
20
|
+
`sys.monitoring` is built for *continuous* event collection (debuggers, coverage,
|
|
21
|
+
profilers), not on-demand snapshots. Concretely, from experiments in this repo:
|
|
22
|
+
|
|
23
|
+
1. **Callbacks fire on the executing thread, not the asker's thread.** A `LINE`
|
|
24
|
+
callback runs inline on whatever thread is running the instrumented bytecode.
|
|
25
|
+
There is no thread-filtering API — you instrument the whole interpreter and
|
|
26
|
+
disambiguate by reading `threading.current_thread()` *inside* the callback.
|
|
27
|
+
To answer "where is the agent" you'd have to keep a running
|
|
28
|
+
`last_frame_by_thread` dict and read the agent's entry from the UI thread.
|
|
29
|
+
That's a continuously-maintained side channel, not a query.
|
|
30
|
+
|
|
31
|
+
2. **Cost.** Global `LINE` instrumentation measured **~3.1x** runtime on a tight
|
|
32
|
+
loop (212ms vs 68ms). `PY_START` and `LINE`+`DISABLE` are ~1.0x — but `DISABLE`
|
|
33
|
+
permanently de-instruments each location until `restart_events()`, so you lose
|
|
34
|
+
line resolution after the first hit. There is no cheap always-on LINE feed.
|
|
35
|
+
|
|
36
|
+
3. **It tells you the *frame*, not the *await*.** The agent is async. When it's
|
|
37
|
+
"stopped" it's usually suspended at an `await` (LLM call, tool, sleep). The
|
|
38
|
+
running OS frame is just `BaseEventLoop._run_once`. What you want is the
|
|
39
|
+
suspended coroutine's stack — which sys.monitoring does not give you.
|
|
40
|
+
|
|
41
|
+
## What works instead (prototype: `agent_locator.py`)
|
|
42
|
+
|
|
43
|
+
Two thread-safe, cheap primitives:
|
|
44
|
+
|
|
45
|
+
- **`sys._current_frames()`** — point-in-time frame for every thread. Safe to
|
|
46
|
+
call from any thread, O(threads). Good for "what is the agent thread executing
|
|
47
|
+
right now" when it's running CPU-bound Python.
|
|
48
|
+
|
|
49
|
+
- **asyncio task introspection** — `asyncio.all_tasks(loop)` + `Task.get_stack()`
|
|
50
|
+
gives the *suspended await stack* of the agent coroutine, which is what "where
|
|
51
|
+
is it stopped" usually means. **Caveat:** `asyncio.Task` is not safe to walk
|
|
52
|
+
from another thread, so the UI thread must hop onto the agent loop first via
|
|
53
|
+
`run_coroutine_threadsafe(locate_agent(loop), loop)` and read the result back.
|
|
54
|
+
Frame data is returned as plain dataclasses, so it crosses the thread boundary
|
|
55
|
+
cleanly. This works even while `handle()` is mid-turn because the snapshot
|
|
56
|
+
coroutine just queues another callback on the same loop.
|
|
57
|
+
|
|
58
|
+
Verified live: the probe correctly reports the running task as
|
|
59
|
+
`TUIAgent.handle :: ActorRuntime._call_plan._execute_with_event` and the agent
|
|
60
|
+
thread's current frame.
|
|
61
|
+
|
|
62
|
+
## Recommendation
|
|
63
|
+
|
|
64
|
+
- For "where is the agent stopped / what is it doing", ship the
|
|
65
|
+
`agent_locator` probe. No core changes; the TUI calls
|
|
66
|
+
`locate_agent_from_other_thread(agent_loop)` from a slash command.
|
|
67
|
+
- The main blind spot: if the agent is blocked *inside a C call or a
|
|
68
|
+
`run_in_executor` thread* (e.g. an LLM HTTP request), `get_stack()` shows the
|
|
69
|
+
suspended Python frame at the `await`, which is exactly the right answer
|
|
70
|
+
("waiting on the model call"), and `_current_frames()` shows the worker thread
|
|
71
|
+
if you want the lower-level detail.
|
|
72
|
+
- Only reach for `sys.monitoring` if you later want a *continuous timeline* of
|
|
73
|
+
what the agent executed (a flight recorder), and accept the perf hit or use
|
|
74
|
+
`PY_START`/sampled `LINE`+`DISABLE`+`restart_events`. That's a different
|
|
75
|
+
feature from the on-demand probe you asked about.
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
[project]
|
|
2
|
+
name = "nooa-cli"
|
|
3
|
+
# Version is derived from git tags at build time by uv-dynamic-versioning.
|
|
4
|
+
dynamic = ["version"]
|
|
5
|
+
description = "CLI for nemo-oo-agents (`nooa` command: eval runner, trace viewer, config)"
|
|
6
|
+
license = {text = "Apache-2.0"}
|
|
7
|
+
readme = "README.md"
|
|
8
|
+
requires-python = ">=3.12,<3.14"
|
|
9
|
+
dependencies = [
|
|
10
|
+
# Floor reflects the actual minimum-compatible core (bump when the cli
|
|
11
|
+
# starts to require a newer core API). No auto-lockstep — published
|
|
12
|
+
# wheels declare what they actually need, not what was co-released.
|
|
13
|
+
"nooa",
|
|
14
|
+
"click>=8.1.0",
|
|
15
|
+
# CLI config files
|
|
16
|
+
"pyyaml>=6.0",
|
|
17
|
+
]
|
|
18
|
+
|
|
19
|
+
[project.urls]
|
|
20
|
+
Homepage = "https://github.com/NVIDIA-NeMo/labs-OO-Agents"
|
|
21
|
+
Repository = "https://github.com/NVIDIA-NeMo/labs-OO-Agents"
|
|
22
|
+
Issues = "https://github.com/NVIDIA-NeMo/labs-OO-Agents/issues"
|
|
23
|
+
|
|
24
|
+
[project.scripts]
|
|
25
|
+
nooa = "nooa_cli:main"
|
|
26
|
+
|
|
27
|
+
[project.entry-points."nooa.skills"]
|
|
28
|
+
"nemo.repo" = "nooa_cli.tools.repo_tools:RepoTools"
|
|
29
|
+
|
|
30
|
+
[project.optional-dependencies]
|
|
31
|
+
# AST-aware code analysis for RepoTools (tree-sitter grammars).
|
|
32
|
+
# The CLI works without these — RepoTools falls back to regex.
|
|
33
|
+
ast = [
|
|
34
|
+
"tree-sitter>=0.23.0",
|
|
35
|
+
"tree-sitter-python>=0.23.0",
|
|
36
|
+
"tree-sitter-javascript>=0.23.0",
|
|
37
|
+
"tree-sitter-typescript>=0.23.0",
|
|
38
|
+
"tree-sitter-go>=0.23.0",
|
|
39
|
+
"tree-sitter-rust>=0.23.0",
|
|
40
|
+
]
|
|
41
|
+
# Data-science stack pre-loaded into the agent's REPL execution namespace
|
|
42
|
+
# (np, pd, px, go, scipy, sklearn). Soft-imported via try/except; they
|
|
43
|
+
# exist purely so LLM-generated CodeAct cells can use these libs without
|
|
44
|
+
# first failing on a missing import.
|
|
45
|
+
datascience = [
|
|
46
|
+
"numpy>=1.24.0",
|
|
47
|
+
"pandas>=2.0.0",
|
|
48
|
+
"plotly>=5.0.0",
|
|
49
|
+
"scipy>=1.10.0",
|
|
50
|
+
"scikit-learn>=1.3.0",
|
|
51
|
+
]
|
|
52
|
+
|
|
53
|
+
[tool.uv.sources]
|
|
54
|
+
nooa = { workspace = true }
|
|
55
|
+
|
|
56
|
+
[build-system]
|
|
57
|
+
requires = ["hatchling>=1.26.0", "uv-dynamic-versioning>=0.14.0"]
|
|
58
|
+
build-backend = "hatchling.build"
|
|
59
|
+
|
|
60
|
+
[tool.hatch.version]
|
|
61
|
+
source = "uv-dynamic-versioning"
|
|
62
|
+
|
|
63
|
+
[tool.uv-dynamic-versioning]
|
|
64
|
+
vcs = "git"
|
|
65
|
+
style = "pep440"
|
|
66
|
+
bump = true
|
|
67
|
+
metadata = false
|
|
68
|
+
fallback-version = "0.0.6"
|
|
69
|
+
|
|
70
|
+
[tool.hatch.build.targets.wheel]
|
|
71
|
+
packages = ["src/nooa_cli"]
|