π€― LobeHub - Super-Agents on Your Team. Add super-agents to the chats your team already uses.They take on work by themselves and get better every week.
TypeScript agentagent-collaborationagent-harnessloop-engineeringmcppersonal-assistantproactive-agentskillssuper-agenttask-management
β¨ feat(cli): output verification URL after evidence submit (#17460)
Inneibbc5826f3bde
diff --git a/apps/cli/src/commands/acceptanceRun.ts b/apps/cli/src/commands/acceptanceRun.tsindex ea4109b0835..99922147507 100644--- a/apps/cli/src/commands/acceptanceRun.ts+++ b/apps/cli/src/commands/acceptanceRun.ts@@ -6,6 +6,7 @@ import type { Command } from 'commander';import pc from 'picocolors';import { getTrpcClient } from '../api/client';+import { resolveServerUrl } from '../settings';import { confirm, outputJson, printTable, timeAgo, truncate } from '../utils/format';import { log } from '../utils/logger';import type { IgnoreResult, LinkResult } from '../utils/skillWiring';@@ -322,8 +323,14 @@ async function submitAction(options: SubmitOptions): Promise<void> {verdict: options.verdict as any,verifyRunId: options.run,});+ const verifyRunId = res.checkResult.verifyRunId ?? options.run;+ if (!verifyRunId) {+ log.error('Submitted result did not resolve to a verification run');+ process.exit(1);+ }+ const url = new URL(`/verify/${verifyRunId}`, resolveServerUrl()).toString();if (options.json !== undefined) {- outputJson(res, typeof options.json === 'string' ? options.json : undefined);+ outputJson({ ...res, url }, typeof options.json === 'string' ? options.json : undefined);return;}console.log(@@ -331,6 +338,7 @@ async function submitAction(options: SubmitOptions): Promise<void> {`${res.checkResult.verdict ? ` (${res.checkResult.verdict})` : ''}` +`${res.evidence.length > 0 ? ` +${res.evidence.length} evidence` : ''}`,);+ console.log(`${pc.bold('report')}: ${url}`);}async function decisionAction(resultId: string, decision: Decision): Promise<void> {diff --git a/apps/cli/src/commands/verify.test.ts b/apps/cli/src/commands/verify.test.tsindex dff2ce36bb5..70cca339e1e 100644--- a/apps/cli/src/commands/verify.test.ts+++ b/apps/cli/src/commands/verify.test.ts@@ -39,6 +39,7 @@ const { getTrpcClient: mockGetTrpcClient } = vi.hoisted(() => ({}));vi.mock('../api/client', () => ({ getTrpcClient: mockGetTrpcClient }));+vi.mock('../settings', () => ({ resolveServerUrl: () => 'https://app.lobehub.com' }));vi.mock('../utils/logger', () => ({log: { debug: vi.fn(), error: vi.fn(), info: vi.fn(), warn: vi.fn() },setVerbose: vi.fn(),@@ -793,6 +794,12 @@ describe('lh acceptance β canonical run tree', () => {beforeEach(() => {consoleSpy = vi.spyOn(console, 'log').mockImplementation(() => {});mockGetTrpcClient.mockResolvedValue(mockTrpcClient);+ (mockTrpcClient.verify as Record<string, any>).submitCheckEvidence = {+ mutate: vi.fn().mockResolvedValue({+ checkResult: { id: 'result_1', verifyRunId: 'run_1' },+ evidence: [{ id: 'evidence_1' }],+ }),+ };});afterEach(() => consoleSpy.mockRestore());@@ -811,6 +818,45 @@ describe('lh acceptance β canonical run tree', () => {expect(mockTrpcClient.verify.deleteRun.mutate).toHaveBeenCalledWith({ verifyRunId: 'run_1' });});+ it('prints the full verification report URL after submitting evidence', async () => {+ await run([+ 'run',+ 'result',+ 'submit',+ '--operation',+ 'op_1',+ '--item',+ 'check_1',+ '--type',+ 'text',+ '--content',+ 'passed',+ ]);++ const lines = consoleSpy.mock.calls.map((call) => String(call[0]));+ expect(lines).toContain('report: https://app.lobehub.com/verify/run_1');+ });++ it('includes the verification report URL in JSON output', async () => {+ await run([+ 'run',+ 'result',+ 'submit',+ '--operation',+ 'op_1',+ '--item',+ 'check_1',+ '--type',+ 'text',+ '--content',+ 'passed',+ '--json',+ ]);++ const output = JSON.parse(consoleSpy.mock.calls.map((call) => String(call[0])).join(''));+ expect(output.url).toBe('https://app.lobehub.com/verify/run_1');+ });+it('exposes `acceptance install` defaulting to the acceptance skill', async () => {const dir = mkdtempSync(path.join(tmpdir(), 'acceptance-install-'));mockTrpcClient.verify.getSkillBundle.query.mockReset().mockResolvedValue({diff --git a/packages/builtin-skills/src/acceptance/SKILL.md b/packages/builtin-skills/src/acceptance/SKILL.mdindex 7e6d76495e3..a9fd0be542a 100644--- a/packages/builtin-skills/src/acceptance/SKILL.md+++ b/packages/builtin-skills/src/acceptance/SKILL.md@@ -112,7 +112,8 @@ lh acceptance run result submit --operation "$LOBE_OPERATION_ID" --item "$CHECK_`--file` for binaries, `--content` for text β exactly one. Submit one artifact percall; call again for each additional one (same `--item` reuses the row). Leave thepass/fail **verdict** to the review step β only add `--verdict` if your task-explicitly asks you to self-assert the outcome.+explicitly asks you to self-assert the outcome. Every successful submit prints the+full `/verify/<verifyRunId>` report URL. Preserve that URL for the final handoff.## Step 4 β Self-check coverage (do not skip)@@ -132,6 +133,17 @@ must appear at least once in its evidence list. Report it explicitly, e.g.back to Step 3 β a missing artifact holds the delivery at `uncertain` no matterhow good the work is.+### Final handoff (mandatory)++The final response MUST include the full report URL printed by+`lh acceptance run result submit`, together with the explicit coverage result.+Do not finish with only a check-result id, local artifact path, or prose claim.++```text+Verification report: https://app.lobehub.com/verify/<verifyRunId>+Coverage: 2/2 criteria, all required evidence uploaded+```+## Worked example (web criterion, one screenshot)Plan item: _"Settings page shows the new 'Beta features' toggle"_,@@ -152,6 +164,7 @@ agent-browser --session app screenshot ./proof/settings-beta.pnglh acceptance run result submit --operation "$OP" --item vci_settings --type screenshot \--file ./proof/settings-beta.png --by agent-browser \--desc "Settings page renders the new Beta features toggle"+# β report: https://app.lobehub.com/verify/<verifyRunId># 4. self-checklh acceptance run result list --operation "$OP" --json # β { checkItemId: vci_settings, id: vcr_77 }