added donna skills command#74
Merged
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
Adds a donna skill CLI command for printing built-in, workspace-independent documentation, and refactors workspace/protocol initialization so CLI commands can consistently install global context when needed.
Changes:
- Introduces
donna skill <document>backed by embedded Markdown fixtures (usage,configuration,initialization,artifacts). - Refactors workspace loading/initialization to return a
Workspaceobject and centralizes global installation viainstall_workspace. - Updates README and bundled fixture specs/workflows to reference
donna skill ...instead of./.agents/donna/usage/*.donna.md; removes legacy usage spec fixtures.
Reviewed changes
Copilot reviewed 30 out of 30 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
| README.md | Updates user-facing docs to point to donna skill ... documentation. |
| donna/workspaces/initialization.py | Adds load_workspace() and adjusts runtime/workspace initialization to return/install Workspace. |
| donna/workspaces/config.py | Introduces Workspace model and install_workspace() helper for global workspace installation. |
| donna/skills/fixtures/usage.md | Adds built-in “usage” skill document content. |
| donna/skills/fixtures/initialization.md | Adds built-in “initialization” skill document content. |
| donna/skills/fixtures/configuration.md | Adds built-in “configuration” skill document content. |
| donna/skills/fixtures/artifacts.md | Adds built-in “artifacts” skill document content. |
| donna/skills/fixtures.py | Adds loader for embedded skill-document fixtures. |
| donna/skills/entities.py | Defines SkillDocument enum for selecting skill documents. |
| donna/skills/init.py | Exports skill-document entities/loader at package level. |
| donna/fixtures/specs/usage/worlds.donna.md | Removes legacy usage spec fixture. |
| donna/fixtures/specs/usage/cli.donna.md | Removes legacy usage spec fixture. |
| donna/fixtures/specs/usage/artifacts.donna.md | Removes legacy usage spec fixture. |
| donna/fixtures/specs/rfc/work/request.donna.md | Updates workflow text to reference donna skill artifacts. |
| donna/fixtures/specs/rfc/work/plan.donna.md | Updates workflow text to reference donna skill artifacts. |
| donna/fixtures/specs/rfc/work/design.donna.md | Updates workflow text to reference donna skill artifacts. |
| donna/fixtures/specs/rfc/specs/request_for_change.donna.md | Updates spec text to reference donna skill artifacts. |
| donna/fixtures/specs/rfc/specs/design.donna.md | Updates spec text to reference donna skill artifacts. |
| donna/fixtures/specs/research/work/research.donna.md | Updates workflow text to reference donna skill artifacts. |
| donna/fixtures/specs/research/specs/report.donna.md | Updates spec text to reference donna skill artifacts. |
| donna/fixtures/specs/intro.donna.md | Updates intro instructions to reference donna skill usage. |
| donna/cli/utils.py | Replaces decorator-based init with a command_context() helper to install protocol/workspace/context. |
| donna/cli/entities.py | Adds GlobalOptions model for callback-provided protocol/root options. |
| donna/cli/commands/workspaces.py | Refactors commands to use command_context() and direct cell writing. |
| donna/cli/commands/skills.py | Adds skill command that prints embedded skill docs as markdown cells. |
| donna/cli/commands/sessions.py | Refactors session commands to use command_context() and direct cell writing. |
| donna/cli/commands/artifacts.py | Refactors artifact commands to use command_context() and direct cell writing. |
| donna/cli/application.py | Stores global options in typer.Context.meta instead of initializing immediately. |
| donna/cli/main.py | Registers the new skills command module. |
| changes/unreleased.md | Replaces prior migration/change notes with a high-level “rethinking” statement. |
Comments suppressed due to low confidence (1)
donna/skills/fixtures/configuration.md:137
- Same typo appears in the multi-line example:
taskwarior.shlooks unintended and will likely confuse users copying the snippet. Consider correcting it (e.g.,taskwarrior.sh) or using a generic placeholder.
```toml
[journal]
cmd = [
"./bin/taskwarior.sh",
"log",
"+journal",
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+210
to
+218
| def install_workspace(workspace: Workspace) -> None: | ||
| if not project_dir.is_set(): | ||
| project_dir.set(pathlib.Path(workspace.root)) | ||
|
|
||
| if not config_dir.is_set(): | ||
| config_dir.set(pathlib.Path(workspace.config_dir)) | ||
|
|
||
| if not config.is_set(): | ||
| config.set(workspace.config) |
Comment on lines
+43
to
44
| workspace_config.protocol.set(self.protocol) | ||
|
|
|
|
||
|
|
||
| def load_skill_text(document: SkillDocument = SkillDocument.usage) -> str: | ||
| return importlib.resources.files(__package__).joinpath("fixtures", _FIXTURES[document]).read_text(encoding="utf-8") |
|
|
||
|
|
||
| @app.command("skill", help="Print built-in Donna skill documentation.") | ||
| def skill(context: typer.Context, document: Annotated[SkillDocument, typer.Argument()] = SkillDocument.usage) -> None: |
|
|
||
| ```toml | ||
| [journal] | ||
| cmd = ["./bin/taskwarior.sh", "log", "+journal", "+donna", "{message}"] |
Comment on lines
+110
to
+116
| Example: | ||
|
|
||
| ```toml | ||
| [journal] | ||
| cmd = ["./bin/taskwarior.sh", "log", "+journal", "+donna", "{message}"] | ||
| ``` | ||
|
|
| **This release is dedicated to a full rethinking of what Donna is and how it works.** | ||
|
|
||
| ### Changes | ||
| The scope of tool functionality was reduced to interpreting state machines for agents (no artifact management, no session management, etc.). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.