Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion e2e/account-portal.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,6 @@ test('mobile account list recovers from failure and previews a named restore wit
expect(box!.x).toBeGreaterThanOrEqual(0);
expect(box!.x + box!.width).toBeLessThanOrEqual(375);
}
await page.screenshot({ path: '/tmp/omni-account-ux-mobile.png' });
await page.keyboard.press('Escape');
await expect(preview).toHaveCount(0);
await expect(account).toBeFocused();
Expand Down
83 changes: 7 additions & 76 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 0 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@
},
"dependencies": {
"@dnd-kit/core": "^6.3.1",
"@modelcontextprotocol/client": "2.3.1",
"clsx": "^2.1.1",
"cmdk": "^1.1.1",
"framer-motion": "^14.3.0",
Expand All @@ -51,7 +50,6 @@
"devDependencies": {
"@anthropic-ai/sdk": "^0.135.0",
"@cloudflare/vite-plugin": "^1.64.0",
"@modelcontextprotocol/server": "2.3.1",
"@playwright/test": "^1.64.1",
"@tailwindcss/postcss": "^4",
"@testing-library/dom": "^10.4.2",
Expand Down
6 changes: 3 additions & 3 deletions scripts/lib/drafters.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@

import Anthropic from '@anthropic-ai/sdk';

export type DraftProvider = 'anthropic' | 'openai' | 'google';
type DraftProvider = 'anthropic' | 'openai' | 'google';

export const DEFAULT_MODELS: Record<DraftProvider, string> = {
const DEFAULT_MODELS: Record<DraftProvider, string> = {
anthropic: 'claude-opus-5-5',
openai: 'gpt-5',
google: 'gemini-2.5-pro'
Expand All @@ -22,7 +22,7 @@ const KEY_ENV: Record<Exclude<DraftProvider, 'anthropic'>, string> = {
const MAX_OUTPUT_TOKENS = 64_000;
const REQUEST_TIMEOUT_MS = 10 * 60_000;

export interface DraftSession {
interface DraftSession {
provider: DraftProvider;
model: string;
/** Send one user turn (the first carries the documents) and return the reply's text. */
Expand Down
2 changes: 1 addition & 1 deletion scripts/lib/verifySpec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export interface QualityResult {
}

/** Inputs from the spec itself: every required input's example, plus one-value constants. */
export function sampleInput(manifest: CapabilityManifest): { ok: true; input: Record<string, unknown> } | { ok: false; missing: string[] } {
function sampleInput(manifest: CapabilityManifest): { ok: true; input: Record<string, unknown> } | { ok: false; missing: string[] } {
const input: Record<string, unknown> = {};
const missing: string[] = [];
for (const field of manifest.inputs) {
Expand Down
3 changes: 1 addition & 2 deletions src/app/CitadelApp.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { Sidebar } from '@/components/Sidebar';
import { TopBar } from '@/components/TopBar';
import { CommandPalette } from '@/components/CommandPalette';
import { ShellPanel } from '@/components/ShellPanel';
import { MindPanel } from '@/components/mind';
import { MindPanel } from '@/components/mind/MindPanel';
import { MindDock } from '@/components/mind/MindDock';
import { SettingsPanel } from '@/components/settings/SettingsPanel';
import { ContextCaptureModal } from '@/components/mind/ContextCaptureModal';
Expand Down Expand Up @@ -59,7 +59,6 @@ export default function CitadelApp() {

if (text && text.length > 0) {
captureSelection({ text });
// windowSelection?.removeAllRanges(); // Optional: clear selection
}
}, [activeTool, captureSelection]);
return (
Expand Down
1 change: 0 additions & 1 deletion src/app/globals.css
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
--citadel-primary: #4890f0;
--citadel-primary-glow: #9a6bff;
--citadel-secondary: #90d8f0;
--citadel-accent: #f59be0;

/* Truth Block Colors (Atlas status: success / danger / warning) */
--truth-green: #6ff5a8;
Expand Down
4 changes: 2 additions & 2 deletions src/blocks/capability/CapabilityBlock.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ function isPlainParams(value: unknown): value is Record<string, unknown> {
}

/** The executor's error for a keyed run whose slot is empty this session. */
export function isUnboundKeyError(error: string): boolean {
function isUnboundKeyError(error: string): boolean {
return /^Secret slot \S+ is empty$/.test(error);
}

Expand All @@ -54,7 +54,7 @@ function isRefusal(error: string): boolean {
}

/** What an HTTP status usually means for the person running the block. */
export function errorHint(error: string): string | null {
function errorHint(error: string): string | null {
const status = /\bHTTP (\d{3})\b/.exec(error)?.[1];
if (status === '401' || status === '403') return 'The API refused the request. Check the key, or whether your plan covers this call.';
if (status === '400') return 'The API rejected the request. Check the inputs, and the key if it takes one.';
Expand Down
4 changes: 1 addition & 3 deletions src/blocks/capability/CapabilityInputs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ import { looksLikeKey } from '@/core/capabilities/credentialName';
import type { ValueType } from '@/core/capabilities/valueType';
import { isPlainList } from '@/core/capabilities/httpTarget';

export { looksLikeKey };

/** What one field holds while being edited: text, or a checkbox's boolean. */
type FieldDraft = string | boolean;
/** A body laid out as fields keeps one draft per property. */
Expand Down Expand Up @@ -294,7 +292,7 @@ function Field({ input, idPrefix, value, wiredValue, onChange, disabled }: {
);
}

export interface CapabilityInputsProps {
interface CapabilityInputsProps {
inputs: readonly CapabilityInput[];
params: Record<string, unknown>;
/** Values arriving on wires. A typed value overrides them. */
Expand Down
17 changes: 5 additions & 12 deletions src/blocks/persona/PersonaBlock.component.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ describe('PersonaBlockView — UI wiring', () => {
mockStream(['Markets look ', 'stable today.'], {
success: true,
content: 'Markets look stable today.',
sourceIds: [],
sources: []
});
render(<PersonaBlockView instanceId={PERSONA_ID} />);
Expand All @@ -79,7 +78,6 @@ describe('PersonaBlockView — UI wiring', () => {
mockStream(['Grounded ', 'answer.'], {
success: true,
content: 'Grounded answer.',
sourceIds: [],
sources: []
});
render(<PersonaBlockView instanceId={PERSONA_ID} />);
Expand All @@ -99,7 +97,6 @@ describe('PersonaBlockView — UI wiring', () => {
it('engine failure surfaces a clear in-chat warning (no fake answer)', async () => {
mockStream([], {
success: false,
sourceIds: [],
sources: [],
error: 'No LLM available — make sure Ollama is running (localhost:11434).'
});
Expand All @@ -124,7 +121,6 @@ describe('PersonaBlockView — provenance', () => {
mockStream(['Grounded.'], {
success: true,
content: 'Grounded.',
sourceIds: ['src-fred'],
sources: [{ id: 'src-fred', kind: 'wire', label: 'FRED Series' }]
});
render(<PersonaBlockView instanceId={PERSONA_ID} />);
Expand All @@ -138,7 +134,6 @@ describe('PersonaBlockView — provenance', () => {
mockStream(['ok'], {
success: true,
content: 'ok',
sourceIds: ['src-fred'],
sources: [{ id: 'src-fred', kind: 'wire', label: 'FRED Series' }]
});
render(<PersonaBlockView instanceId={PERSONA_ID} />);
Expand All @@ -158,7 +153,6 @@ describe('PersonaBlockView — provenance', () => {
mockStream(['from memory'], {
success: true,
content: 'from memory',
sourceIds: [],
sources: [{ id: 'mem-block-1', kind: 'memory', label: 'Long-term memory' }]
});
render(<PersonaBlockView instanceId={PERSONA_ID} />);
Expand All @@ -172,7 +166,6 @@ describe('PersonaBlockView — provenance', () => {
mockStream(['general reasoning'], {
success: true,
content: 'general reasoning',
sourceIds: [],
sources: []
});
render(<PersonaBlockView instanceId={PERSONA_ID} />);
Expand All @@ -194,7 +187,7 @@ describe('PersonaBlockView — answer rendering', () => {
const md = '## Outlook' + String.fromCharCode(10) + String.fromCharCode(10) +
'Rates are **steady**.' + String.fromCharCode(10) + String.fromCharCode(10) +
'- 10y near 4.2%' + String.fromCharCode(10) + '- CPI cooling';
mockStream([md], { success: true, content: md, sourceIds: [], sources: [] });
mockStream([md], { success: true, content: md, sources: [] });
render(<PersonaBlockView instanceId={PERSONA_ID} />);
fireEvent.click(screen.getByTitle('Think'));

Expand All @@ -209,7 +202,7 @@ describe('PersonaBlockView — answer rendering', () => {
it('does not execute HTML embedded in an answer', async () => {
// Answers can quote text that arrived from an external feed.
const hostile = 'Look: <img src=x onerror="alert(1)">';
mockStream([hostile], { success: true, content: hostile, sourceIds: [], sources: [] });
mockStream([hostile], { success: true, content: hostile, sources: [] });
const { container } = render(<PersonaBlockView instanceId={PERSONA_ID} />);
fireEvent.click(screen.getByTitle('Think'));

Expand All @@ -218,7 +211,7 @@ describe('PersonaBlockView — answer rendering', () => {
});

it('offers lineage only on an answer the ledger recorded', async () => {
mockStream(['Recorded.'], { success: true, content: 'Recorded.', sourceIds: [], sources: [], runId: '42' });
mockStream(['Recorded.'], { success: true, content: 'Recorded.', sources: [], runId: '42' });
render(<PersonaBlockView instanceId={PERSONA_ID} />);
fireEvent.click(screen.getByTitle('Think'));

Expand All @@ -227,7 +220,7 @@ describe('PersonaBlockView — answer rendering', () => {
});

it('offers no lineage when no run was recorded', async () => {
mockStream(['Unrecorded.'], { success: true, content: 'Unrecorded.', sourceIds: [], sources: [] });
mockStream(['Unrecorded.'], { success: true, content: 'Unrecorded.', sources: [] });
render(<PersonaBlockView instanceId={PERSONA_ID} />);
fireEvent.click(screen.getByTitle('Think'));

Expand All @@ -236,7 +229,7 @@ describe('PersonaBlockView — answer rendering', () => {
});

it("leaves the user's own message as literal text", async () => {
mockStream(['ok'], { success: true, content: 'ok', sourceIds: [], sources: [] });
mockStream(['ok'], { success: true, content: 'ok', sources: [] });
render(<PersonaBlockView instanceId={PERSONA_ID} />);

const input = screen.getByPlaceholderText(/Ask Analyst/);
Expand Down
2 changes: 1 addition & 1 deletion src/blocks/persona/RunLineage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ const NOT_RECORDED =
'The inference ledger is not configured here, so no lineage was recorded for this answer.';

/** Map every non-tree answer to one honest sentence. */
export async function fetchLineage(runId: string): Promise<LoadState> {
async function fetchLineage(runId: string): Promise<LoadState> {
let res: Response;
try {
res = await fetch(`/api/inference-runs/${encodeURIComponent(runId)}/lineage`, { cache: 'no-store' });
Expand Down
5 changes: 0 additions & 5 deletions src/blocks/persona/index.ts

This file was deleted.

Loading
Loading