Skip to content

Commit 082b18b

Browse files
Merge pull request #9 from NVIDIA-NeMo/chore/strip-tui
Chore/strip tui
2 parents bdd05a7 + 94f98cc commit 082b18b

16 files changed

Lines changed: 27 additions & 1818 deletions

File tree

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,14 +61,14 @@ uv add "nooa @ git+https://github.com/NVIDIA-NeMo/labs-OO-Agents.git@main"
6161
```
6262

6363
<details>
64-
<summary><b>Optional sub-packages</b> — CLI + TUI, memory, evaluation pipeline</summary>
64+
<summary><b>Optional sub-packages</b> — CLI, memory, evaluation pipeline</summary>
6565

6666
<br />
6767

6868
All of these live in the same repo and are addressed with `#subdirectory=…`.
6969

7070
```bash
71-
# CLI + TUI (beta): the `nooa` command, agent REPL, trace viewer, TUI
71+
# CLI (beta): the `nooa` command, trace viewer, eval runner
7272
uv add "nooa-cli @ git+https://github.com/NVIDIA-NeMo/labs-OO-Agents.git@main#subdirectory=packages/nooa-cli"
7373

7474
# Long-term memory subsystem (MemoryManager)

THIRD_PARTY_NOTICES.md

Lines changed: 0 additions & 98 deletions
Original file line numberDiff line numberDiff line change
@@ -50,90 +50,16 @@ Attribution Statements: NVIDIA includes `click` under the BSD 3-Clause License f
5050
License Text(https://spdx.org/licenses/BSD-3-Clause.html)
5151
Source/Homepage: https://github.com/pallets/click
5252

53-
ipython - BSD 3-Clause License
54-
Attribution Statements: NVIDIA includes `ipython` under the BSD 3-Clause License for use with NVIDIA OO Agents.
55-
License Text(https://spdx.org/licenses/BSD-3-Clause.html)
56-
Source/Homepage: https://github.com/ipython/ipython
57-
58-
mcp - MIT License
59-
Attribution Statements: NVIDIA includes `mcp` under the MIT License for use with NVIDIA OO Agents.
60-
License Text(https://spdx.org/licenses/MIT.html)
61-
Source/Homepage: https://github.com/modelcontextprotocol/python-sdk
62-
6353
nooa - Apache License 2.0
6454
Attribution Statements: NVIDIA includes `nooa` under the Apache License 2.0 for use with NVIDIA OO Agents.
6555
License Text(https://spdx.org/licenses/Apache-2.0.html)
6656
Source/Homepage: https://github.com/NVIDIA-NeMo/labs-OO-Agents
6757

68-
prompt-toolkit - BSD 3-Clause License
69-
Attribution Statements: NVIDIA includes `prompt-toolkit` under the BSD 3-Clause License for use with NVIDIA OO Agents.
70-
License Text(https://spdx.org/licenses/BSD-3-Clause.html)
71-
Source/Homepage: https://github.com/prompt-toolkit/python-prompt-toolkit
72-
73-
pydantic - MIT License
74-
Attribution Statements: NVIDIA includes `pydantic` under the MIT License for use with NVIDIA OO Agents.
75-
License Text(https://spdx.org/licenses/MIT.html)
76-
Source/Homepage: https://github.com/pydantic/pydantic
77-
7858
pyyaml - MIT License
7959
Attribution Statements: NVIDIA includes `pyyaml` under the MIT License for use with NVIDIA OO Agents.
8060
License Text(https://spdx.org/licenses/MIT.html)
8161
Source/Homepage: https://github.com/yaml/pyyaml
8262

83-
rich - MIT License
84-
Attribution Statements: NVIDIA includes `rich` under the MIT License for use with NVIDIA OO Agents.
85-
License Text(https://spdx.org/licenses/MIT.html)
86-
Source/Homepage: https://github.com/Textualize/rich
87-
88-
---
89-
90-
## `nooa-tui`
91-
92-
click - BSD 3-Clause License
93-
Attribution Statements: NVIDIA includes `click` under the BSD 3-Clause License for use with NVIDIA OO Agents.
94-
License Text(https://spdx.org/licenses/BSD-3-Clause.html)
95-
Source/Homepage: https://github.com/pallets/click
96-
97-
ipython - BSD 3-Clause License
98-
Attribution Statements: NVIDIA includes `ipython` under the BSD 3-Clause License for use with NVIDIA OO Agents.
99-
License Text(https://spdx.org/licenses/BSD-3-Clause.html)
100-
Source/Homepage: https://github.com/ipython/ipython
101-
102-
mcp - MIT License
103-
Attribution Statements: NVIDIA includes `mcp` under the MIT License for use with NVIDIA OO Agents.
104-
License Text(https://spdx.org/licenses/MIT.html)
105-
Source/Homepage: https://github.com/modelcontextprotocol/python-sdk
106-
107-
nooa - Apache License 2.0
108-
Attribution Statements: NVIDIA includes `nooa` under the Apache License 2.0 for use with NVIDIA OO Agents.
109-
License Text(https://spdx.org/licenses/Apache-2.0.html)
110-
Source/Homepage: https://github.com/NVIDIA-NeMo/labs-OO-Agents
111-
112-
nooa-cli - Apache License 2.0
113-
Attribution Statements: NVIDIA includes `nooa-cli` under the Apache License 2.0 for use with NVIDIA OO Agents.
114-
License Text(https://spdx.org/licenses/Apache-2.0.html)
115-
Source/Homepage: https://github.com/NVIDIA-NeMo/labs-OO-Agents
116-
117-
prompt-toolkit - BSD 3-Clause License
118-
Attribution Statements: NVIDIA includes `prompt-toolkit` under the BSD 3-Clause License for use with NVIDIA OO Agents.
119-
License Text(https://spdx.org/licenses/BSD-3-Clause.html)
120-
Source/Homepage: https://github.com/prompt-toolkit/python-prompt-toolkit
121-
122-
pydantic - MIT License
123-
Attribution Statements: NVIDIA includes `pydantic` under the MIT License for use with NVIDIA OO Agents.
124-
License Text(https://spdx.org/licenses/MIT.html)
125-
Source/Homepage: https://github.com/pydantic/pydantic
126-
127-
pyyaml - MIT License
128-
Attribution Statements: NVIDIA includes `pyyaml` under the MIT License for use with NVIDIA OO Agents.
129-
License Text(https://spdx.org/licenses/MIT.html)
130-
Source/Homepage: https://github.com/yaml/pyyaml
131-
132-
rich - MIT License
133-
Attribution Statements: NVIDIA includes `rich` under the MIT License for use with NVIDIA OO Agents.
134-
License Text(https://spdx.org/licenses/MIT.html)
135-
Source/Homepage: https://github.com/Textualize/rich
136-
13763
---
13864

13965
## `nemo-oo-agents-benchmarks`
@@ -369,30 +295,6 @@ Source/Homepage: https://github.com/scipy/scipy
369295

370296
---
371297

372-
## `nooa-cli[web]`
373-
374-
fastapi - MIT License
375-
Attribution Statements: NVIDIA includes `fastapi` under the MIT License for use with NVIDIA OO Agents.
376-
License Text(https://spdx.org/licenses/MIT.html)
377-
Source/Homepage: https://github.com/fastapi/fastapi
378-
379-
nooa-cli[datascience] - Apache License 2.0
380-
Attribution Statements: NVIDIA includes `nooa-cli[datascience]` under the Apache License 2.0 for use with NVIDIA OO Agents.
381-
License Text(https://spdx.org/licenses/Apache-2.0.html)
382-
Source/Homepage: https://github.com/NVIDIA-NeMo/labs-OO-Agents
383-
384-
ptyprocess - ISC License
385-
Attribution Statements: NVIDIA includes `ptyprocess` under the ISC License for use with NVIDIA OO Agents.
386-
License Text(https://spdx.org/licenses/ISC.html)
387-
Source/Homepage: https://github.com/pexpect/ptyprocess
388-
389-
uvicorn - BSD 3-Clause License
390-
Attribution Statements: NVIDIA includes `uvicorn` under the BSD 3-Clause License for use with NVIDIA OO Agents.
391-
License Text(https://spdx.org/licenses/BSD-3-Clause.html)
392-
Source/Homepage: https://github.com/encode/uvicorn
393-
394-
---
395-
396298
## `nemo-oo-agents-benchmarks[bigcodebench]`
397299

398300
beautifulsoup4 - MIT License

docs/guides/config-migration.md

Lines changed: 3 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -18,60 +18,7 @@ wins). Here's everything you need to move.
1818

1919
`NAT_CONFIG_DIR` is gone — use `NEMO_OO_USER_DIR` to relocate the user dir.
2020

21-
## 2. TUI settings: `config.toml``settings.yaml`
22-
23-
Project-only TOML becomes layered YAML (`<project>/.nooa/settings.yaml` or
24-
user-global `~/.config/nooa/settings.yaml`). **Hard switch — `config.toml`
25-
is no longer read.**
26-
27-
**Before — `config.toml`**
28-
```toml
29-
[tui]
30-
model = "claude-opus-4-8"
31-
python = false
32-
vi = false
33-
trace = ".nooa/traces"
34-
mcp_auto_connect = ["maas"]
35-
36-
[tui.mcp_servers.maas]
37-
url = "https://your-mcp-server.example.com/mcp"
38-
transport = "streamable-http"
39-
40-
[tui.mcp_servers.maas.headers]
41-
Authorization = "Bearer ${MAAS_API_KEY}"
42-
```
43-
44-
**After — `settings.yaml`**
45-
```yaml
46-
tui:
47-
default_model: claude-opus-4-8
48-
show_python: false
49-
vi_mode: false
50-
trace_dir: .nooa/traces
51-
mcp_auto_connect: [maas]
52-
mcp_servers:
53-
maas:
54-
url: https://your-mcp-server.example.com/mcp
55-
transport: streamable-http
56-
headers:
57-
Authorization: "Bearer ${MAAS_API_KEY}"
58-
```
59-
60-
Key renames (YAML uses the real field names):
61-
62-
| `config.toml` | `settings.yaml` |
63-
|---------------|-----------------|
64-
| `[tui]` table | `tui:` mapping |
65-
| `model` | `default_model` |
66-
| `python` | `show_python` |
67-
| `vi` | `vi_mode` |
68-
| `trace` | `trace_dir` |
69-
| `libs_dirs`, `mcp_auto_connect` | *(unchanged)* |
70-
| `[tui.mcp_servers.<name>]` | `tui.mcp_servers.<name>:` |
71-
72-
(`/config set model …` still works — friendly keys map to the field names.)
73-
74-
## 3. API keys / secrets
21+
## 2. API keys / secrets
7522

7623
| Before | After |
7724
|--------|-------|
@@ -88,14 +35,14 @@ A shell `export` still wins (non-clobber), so existing exports keep working —
8835
`secrets.yaml` just means you no longer *need* one. The installer writes this
8936
file for you.
9037

91-
## 4. LLM aliases: `llm_config.yaml`
38+
## 3. LLM aliases: `llm_config.yaml`
9239

9340
Same filename and format — just move it to the new dir:
9441
`~/.config/nat/oo/llm_config.yaml``~/.config/nooa/llm_config.yaml`
9542
(or `<project>/.nooa/llm_config.yaml`). `nooa config eject` regenerates
9643
a fresh copy in the new location.
9744

98-
## 5. Environment variables → `NEMO_OO_` prefix
45+
## 4. Environment variables → `NEMO_OO_` prefix
9946

10047
| Before | After |
10148
|--------|-------|

examples/README.md

Lines changed: 1 addition & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -476,32 +476,7 @@ uv run python examples/quickstart/10_skills.py
476476

477477
### MCP tools
478478

479-
MCP (Model Context Protocol) tools let your agent call external services through a standard interface. The TUI ships MCP as a hard dependency (`self.mcp` and `/mcp` are always available). In the core library, MCP is an optional extra (`uv add 'nooa[mcp]'`).
480-
481-
**TUI configuration** — declare MCP servers in `.nooa/settings.yaml`:
482-
483-
```yaml
484-
tui:
485-
mcp_auto_connect: ["maas-confluence-stg"]
486-
mcp_servers:
487-
maas-confluence-stg:
488-
url: "https://your-mcp-server.example.com/mcp"
489-
transport: "streamable-http"
490-
headers:
491-
Authorization: "Bearer ${MAAS_API_KEY}"
492-
```
493-
494-
At startup the TUI attaches auto-connected servers to the agent, so `maas-confluence-stg` becomes `self.maas_confluence_stg`. A VS Code / Claude-style `.mcp.json` file is also supported via `mcp_file` or `--mcp-file`.
495-
496-
Inside the TUI, servers are managed through `self.mcp` (an `MCPRegistry` skill that mirrors `self.skills`):
497-
498-
- `self.mcp.discovered()` — configured server names
499-
- `await self.mcp.connect(["name"])` — open a server and attach it as `self.<name>`
500-
- `self.mcp.activate([...])` / `self.mcp.deactivate([...])` — control whether a connected server's tools are listed for the agent
501-
- `<mcp>` context block lists every server each turn under **Active**, **Connected but inactive**, or **Configured**
502-
- Slash commands: `/mcp list`, `/mcp connect <server>`, `/mcp disconnect <server>`
503-
504-
**Library use** — no `self.mcp`; call the stateless `MCPManager` factory directly:
479+
MCP (Model Context Protocol) tools let your agent call external services through a standard interface. Install with `uv add 'nooa[mcp]'` and call the stateless `MCPManager` factory:
505480

506481
```python
507482
from nooa.mcp import MCPManager

packages/nooa-cli/README.md

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,25 @@
11
# nooa-cli
22

3-
CLI and TUI for [nemo-oo-agents](https://github.com/NVIDIA-NeMo/labs-OO-Agents). Ships the `nooa` command (subcommands like `nooa tui`, `nooa term`, `nooa eval`, `nooa traces`) and the agent TUI (a REPL-driven CodeAct frontend).
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.
44

55
## Install
66

77
```bash
8-
# CLI + TUI
98
uv add nooa-cli
109

1110
# ...with numpy/pandas/plotly/scipy/sklearn pre-loaded into the LLM REPL
1211
uv add "nooa-cli[datascience]"
13-
14-
# ...with web-served TUI (uvicorn + ptyprocess + fastapi, plus datascience)
15-
uv add "nooa-cli[web]"
1612
```
1713

18-
`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; the `[web]` extra adds the `nooa term` web frontend.
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.
1915

2016
## Usage
2117

2218
```bash
2319
nooa --help
24-
nooa tui # interactive agent REPL
25-
nooa term # web terminal
20+
nooa start-dev # launch the trace viewer
2621
nooa eval ... # eval pipeline runner
22+
nooa traces ... # inspect/manage trace files
2723
```
2824

2925
See the main repo [README](https://github.com/NVIDIA-NeMo/labs-OO-Agents/blob/main/README.md) for the framework documentation.

packages/nooa-cli/pyproject.toml

Lines changed: 5 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
name = "nooa-cli"
33
# Version is derived from git tags at build time by uv-dynamic-versioning.
44
dynamic = ["version"]
5-
description = "CLI and TUI for nemo-oo-agents (`nooa` command, web terminal, agent REPL)"
5+
description = "CLI for nemo-oo-agents (`nooa` command: eval runner, trace viewer, config)"
66
license = {text = "Apache-2.0"}
77
readme = "README.md"
88
requires-python = ">=3.12,<3.14"
@@ -12,21 +12,8 @@ dependencies = [
1212
# wheels declare what they actually need, not what was co-released.
1313
"nooa",
1414
"click>=8.1.0",
15-
"ipython>=9.12.0",
16-
# prompt-toolkit and rich were only transitive (via ipython and litellm
17-
# respectively); declare them explicitly so we don't break if those
18-
# transitive paths change.
19-
"prompt-toolkit>=3.0.41,<3.1.0",
20-
"rich>=13.0.0",
21-
# Used directly in tui/agent.py and tui/models.py
22-
"pydantic>=2.5.0",
23-
# CLI/TUI config files
15+
# CLI config files
2416
"pyyaml>=6.0",
25-
# MCP is a first-class TUI capability (self.mcp / MCPRegistry, /mcp command,
26-
# mcp_auto_connect). It stays optional in the *core* package for issue-189
27-
# glibc<2.28 hosts, but the CLI already hard-depends on pydantic, so that
28-
# rationale doesn't apply here — make it a hard dep of the TUI package.
29-
"mcp>=1.0.0",
3017
]
3118

3219
[project.scripts]
@@ -47,26 +34,16 @@ ast = [
4734
"tree-sitter-rust>=0.23.0",
4835
]
4936
# Data-science stack pre-loaded into the agent's REPL execution namespace
50-
# (np, pd, px, go, scipy, sklearn). Soft-imported via try/except in
51-
# TUI agent REPLs work without these too;
52-
# they exist purely so LLM-generated CodeAct cells can use these libs
53-
# without first failing on a missing import.
37+
# (np, pd, px, go, scipy, sklearn). Soft-imported via try/except; they
38+
# exist purely so LLM-generated CodeAct cells can use these libs without
39+
# first failing on a missing import.
5440
datascience = [
5541
"numpy>=1.24.0",
5642
"pandas>=2.0.0",
5743
"plotly>=5.0.0",
5844
"scipy>=1.10.0",
5945
"scikit-learn>=1.3.0",
6046
]
61-
# Web-served TUI (`nooa term`): uvicorn + ptyprocess + fastapi, plus
62-
# the data-science stack so the LLM has the same REPL capabilities as
63-
# in the local terminal.
64-
web = [
65-
"nooa-cli[datascience]",
66-
"uvicorn[standard]>=0.34.0",
67-
"ptyprocess>=0.7.0",
68-
"fastapi>=0.123.4",
69-
]
7047

7148
[tool.uv.sources]
7249
nooa = { workspace = true }

packages/nooa-cli/src/nooa_cli/__init__.py

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,9 @@
2424
CONTEXT_SETTINGS = {"help_option_names": ["-h", "--help"]}
2525

2626

27-
# Thin launcher subcommands that don't touch API keys in *this* process:
28-
# `term` runs a web/PTY server and re-spawns the CLI as a child (which loads
29-
# secrets itself via bootstrap); `completion` just emits a shell script.
30-
# Skipping the secrets preload for them avoids importing the heavy
31-
# ``nooa`` core (~1.5s) on startup — keeping `nooa term` fast and
32-
# its SIGINT shutdown prompt.
33-
_SKIP_SECRETS_PRELOAD = {"term", "completion"}
27+
# `completion` just emits a shell script and doesn't need the ~1.5s core
28+
# import cost or secrets preload.
29+
_SKIP_SECRETS_PRELOAD = {"completion"}
3430

3531

3632
@click.group(context_settings=CONTEXT_SETTINGS)
@@ -45,10 +41,10 @@ def oo(ctx):
4541
if ctx.invoked_subcommand in _SKIP_SECRETS_PRELOAD:
4642
return
4743
# Load secrets.yaml into the process env before any subcommand runs so
48-
# non-TUI commands (config show, eval, …) see the same API keys the TUI
49-
# does. Non-clobbering (shell env wins) and best-effort: a broken or
50-
# missing secrets file must never block the CLI — but log the failure at
51-
# debug so it's recoverable rather than silently swallowed.
44+
# all commands (config show, eval, …) see the same API keys.
45+
# Non-clobbering (shell env wins) and best-effort: a broken or missing
46+
# secrets file must never block the CLI — but log the failure at debug
47+
# so it's recoverable rather than silently swallowed.
5248
try:
5349
from nooa.secrets import load_secrets_into_env
5450

0 commit comments

Comments
 (0)