Skip to content

Add Triton-RISCV operator lifecycle plugin - #1

Open
ada-cl25 wants to merge 2 commits into
RuyiAI-Stack:mainfrom
ada-cl25:triton-riscv-agent-plugin
Open

Add Triton-RISCV operator lifecycle plugin#1
ada-cl25 wants to merge 2 commits into
RuyiAI-Stack:mainfrom
ada-cl25:triton-riscv-agent-plugin

Conversation

@ada-cl25

@ada-cl25 ada-cl25 commented Sep 7, 2026

Copy link
Copy Markdown

Summary

Add an installable DeepSeek Harness bundle for guarded Triton-RISCV operator development and validation.

This plugin:

  • registers Triton-RISCV lifecycle guidance in the Harness system prompt;
  • connects the official Harness MCP client to the Triton-RISCV Python MCP server;
  • exposes typed tools for operator discovery, development, validation, diagnosis, and bounded repair;
  • keeps validation, source modification, and remote execution disabled by default;
  • supports an external Triton-RISCV checkout through TRITON_RISCV_CHECKOUT;
  • documents installation, remote RISC-V configuration, testing, and removal.

The Harness model and Agent loop remain unchanged. The plugin only contributes domain policy and connects the existing Triton-RISCV tools.

Related issue

Related to RuyiAI-Stack/triton-riscv#24.

Validation

Plugin tests:

cd plugins/dsh-triton-riscv
npm test
npm pack --dry-run

@shirohasuki

Copy link
Copy Markdown
Collaborator

Thank you for your contribution. I'm sorry; this is currently blocked on my end. I'll review this PR tonight after I've finished organizing the repository.

@shirohasuki
shirohasuki force-pushed the main branch 4 times, most recently from bf45229 to b2a2653 Compare September 8, 2026 16:56

@shirohasuki shirohasuki left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your time! I have leave some comments.

Comment on lines +1 to +7
You have guarded Triton-RISCV operator tools.

Use the typed tools instead of arbitrary shell commands for operator lifecycle work.

For an existing operator:
1. Call `mcp__triton_riscv__discover_operator`.
2. Call `mcp__triton_riscv__check_validation_environment` before live validation.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest that the management of prompts be made more structured; you may wish to refer to this. We need to split skills, hints, failure experience, success experience, and verification.

For an existing operator:
1. Call `mcp__triton_riscv__discover_operator`.
2. Call `mcp__triton_riscv__check_validation_environment` before live validation.
3. Call `mcp__triton_riscv__validate_operator` with `execute=false` to create a reviewable plan.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will these MCPs be installed in the ‘harness’ repository or in each working directory?

Comment on lines +48 to +52
export TRITON_RISCV_CHECKOUT=/absolute/path/to/triton-riscv
export TRITON_RISCV_MCP_PYTHON="$TRITON_RISCV_CHECKOUT/.harness-venv/bin/python"
export TRITON_RISCV_WORKBENCH_PORT=8765
dsh plugin --profile web add ./plugins/dsh-triton-riscv
dsh --profile web --dump-config

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Most of them can be installed using the repository’s scripts and configuration in the config.yaml. These environment variables are hard to manage when they're scattered everywhere.

throw new Error('TRITON_RISCV_CHECKOUT must be an absolute path')
}

const portText = (env.TRITON_RISCV_WORKBENCH_PORT ?? '8765').trim()

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can do this by passing parameters rather than using environment variables

@@ -0,0 +1,153 @@
import assert from 'node:assert/strict'
import { readFile } from 'node:fs/promises'
import test from 'node:test'

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We use vitest as the test framework.
The checklist could be clearer. We can broadly categorise unit tests into three areas:
The inputs to a plugin (such as hooks and the web), the outputs (such as tools and the front-end UI), and the state (context within the service).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants