ummaya 0.2.3 → 0.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -1
- package/npm-shrinkwrap.json +2 -2
- package/package.json +1 -1
- package/prompts/manifest.yaml +2 -2
- package/prompts/session_guidance_v1.md +3 -1
- package/prompts/system_v1.md +8 -7
- package/pyproject.toml +2 -7
- package/src/ummaya/context/builder.py +17 -11
- package/src/ummaya/engine/engine.py +27 -7
- package/src/ummaya/engine/query.py +20 -0
- package/src/ummaya/evidence/__init__.py +25 -0
- package/src/ummaya/evidence/__main__.py +7 -0
- package/src/ummaya/evidence/models.py +58 -0
- package/src/ummaya/evidence/runner.py +308 -0
- package/src/ummaya/evidence/task_registry.py +264 -0
- package/src/ummaya/ipc/frame_schema.py +47 -0
- package/src/ummaya/ipc/stdio.py +1287 -54
- package/src/ummaya/llm/client.py +132 -56
- package/src/ummaya/llm/reasoning.py +84 -0
- package/src/ummaya/tools/discovery_bridge.py +17 -1
- package/src/ummaya/tools/executor.py +32 -12
- package/src/ummaya/tools/geocoding/kakao_client.py +1 -2
- package/src/ummaya/tools/kma/apihub_catalog.py +984 -1
- package/src/ummaya/tools/kma/apihub_structured_adapter.py +86 -6
- package/src/ummaya/tools/kma/apihub_url_adapter.py +593 -0
- package/src/ummaya/tools/kma/apihub_url_catalog.py +296 -0
- package/src/ummaya/tools/location_adapters.py +8 -6
- package/src/ummaya/tools/manifest_metadata.py +16 -3
- package/src/ummaya/tools/mvp_surface.py +2 -2
- package/src/ummaya/tools/nmc/emergency_search.py +8 -6
- package/src/ummaya/tools/register_all.py +9 -0
- package/src/ummaya/tools/resolve_location.py +4 -4
- package/src/ummaya/tools/search.py +664 -18
- package/src/ummaya/tools/verified_data_go_kr/_manifest.py +115 -25
- package/src/ummaya/tools/verified_data_go_kr/airkorea_air_quality.py +109 -4
- package/src/ummaya/tools/verified_data_go_kr/nmc_aed_site.py +108 -2
- package/src/ummaya/tools/verified_data_go_kr/pps_bid_public_info.py +174 -9
- package/src/ummaya/tools/verified_data_go_kr/tago_bus_arrival.py +66 -3
- package/src/ummaya/tools/verified_data_go_kr/tago_bus_location.py +12 -2
- package/src/ummaya/tools/verified_data_go_kr/tago_bus_route.py +8 -2
- package/src/ummaya/tools/verified_data_go_kr/tago_bus_route_station.py +114 -0
- package/src/ummaya/tools/verified_data_go_kr/tago_bus_station.py +14 -3
- package/src/ummaya/tools/verify_canonical_map.py +21 -0
- package/tui/package.json +1 -2
- package/tui/src/QueryEngine.ts +4 -0
- package/tui/src/cli/handlers/auth.ts +1 -1
- package/tui/src/cli/handlers/mcp.tsx +3 -3
- package/tui/src/cli/print.ts +69 -18
- package/tui/src/cli/update.ts +13 -13
- package/tui/src/commands/copy/index.ts +1 -1
- package/tui/src/commands/cost/cost.ts +2 -2
- package/tui/src/commands/init-verifiers.ts +5 -5
- package/tui/src/commands/init.ts +30 -30
- package/tui/src/commands/insights.ts +43 -43
- package/tui/src/commands/install-github-app/install-github-app.tsx +2 -2
- package/tui/src/commands/install-github-app/setupGitHubActions.ts +3 -3
- package/tui/src/commands/install.tsx +5 -5
- package/tui/src/commands/mcp/addCommand.ts +5 -5
- package/tui/src/commands/mcp/xaaIdpCommand.ts +2 -2
- package/tui/src/commands/plugin/ManageMarketplaces.tsx +2 -2
- package/tui/src/commands/reasoning/index.ts +13 -0
- package/tui/src/commands/reasoning/reasoning.tsx +177 -0
- package/tui/src/commands/thinkback/thinkback.tsx +3 -3
- package/tui/src/commands.ts +2 -0
- package/tui/src/components/Messages.tsx +2 -1
- package/tui/src/components/Spinner.tsx +2 -2
- package/tui/src/components/design-system/LoadingState.tsx +2 -2
- package/tui/src/ipc/codec.ts +26 -0
- package/tui/src/ipc/frames.generated.ts +398 -303
- package/tui/src/ipc/llmClient.ts +130 -51
- package/tui/src/ipc/llmTypes.ts +16 -1
- package/tui/src/ipc/schema/frame.schema.json +1 -3475
- package/tui/src/main.tsx +3 -0
- package/tui/src/query.ts +467 -2
- package/tui/src/screens/REPL.tsx +3 -3
- package/tui/src/services/api/claude.ts +48 -18
- package/tui/src/services/api/client.ts +33 -12
- package/tui/src/services/api/ummaya.ts +70 -16
- package/tui/src/skills/bundled/stuck.ts +12 -12
- package/tui/src/state/AppStateStore.ts +7 -0
- package/tui/src/tools/AdapterTool/AdapterTool.ts +590 -7
- package/tui/src/tools/LookupPrimitive/LookupPrimitive.ts +43 -17
- package/tui/src/tools/LookupPrimitive/prompt.ts +7 -6
- package/tui/src/tools/ResolveLocationPrimitive/ResolveLocationPrimitive.ts +40 -19
- package/tui/src/tools/SubmitPrimitive/SubmitPrimitive.ts +25 -9
- package/tui/src/tools/VerifyPrimitive/VerifyPrimitive.ts +25 -9
- package/tui/src/tools/_shared/citizenUserText.ts +49 -0
- package/tui/src/tools/_shared/directPublicDataGuard.ts +362 -0
- package/tui/src/tools/_shared/kmaAnalysisGuard.ts +197 -0
- package/tui/src/tools/_shared/kmaAviationGuard.ts +70 -0
- package/tui/src/tools/_shared/locationInputRepair.ts +112 -0
- package/tui/src/tools/_shared/nmcAedGuard.ts +234 -0
- package/tui/src/tools/_shared/protectedCheckGuard.ts +207 -0
- package/tui/src/tools/_shared/rootPrimitiveInput.ts +67 -0
- package/tui/src/tools/_shared/textToolCallGuard.ts +91 -0
- package/tui/src/tools/_shared/toolChoiceRepair.ts +866 -0
- package/tui/src/utils/attachments.ts +1 -1
- package/tui/src/utils/kExaoneReasoning.ts +138 -0
- package/tui/src/utils/messages.ts +1 -0
- package/tui/src/utils/multiToolLayout.ts +13 -0
- package/tui/src/utils/processUserInput/processSlashCommand.tsx +2 -2
- package/tui/src/utils/processUserInput/processUserInput.ts +26 -0
- package/tui/src/utils/settings/applySettingsChange.ts +4 -0
- package/tui/src/utils/settings/types.ts +9 -3
- package/tui/src/utils/stats.ts +1 -1
- package/uv.lock +1 -15
- package/assets/copilot-gate-logo.svg +0 -58
- package/assets/govon-logo.svg +0 -40
- package/src/ummaya/eval/__init__.py +0 -5
- package/src/ummaya/eval/retrieval.py +0 -713
- package/tui/src/utils/messageStream.ts +0 -186
|
@@ -3519,7 +3519,7 @@ async function getAsyncHookResponseAttachments(): Promise<Attachment[]> {
|
|
|
3519
3519
|
|
|
3520
3520
|
/**
|
|
3521
3521
|
* Get teammate mailbox attachments for agent swarm communication
|
|
3522
|
-
* Teammates are independent
|
|
3522
|
+
* Teammates are independent UMMAYA sessions running in parallel (swarms),
|
|
3523
3523
|
* not parent-child subagent relationships.
|
|
3524
3524
|
*
|
|
3525
3525
|
* This function checks two sources for messages:
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
export const REASONING_MODES = [
|
|
2
|
+
'fast',
|
|
3
|
+
'balanced',
|
|
4
|
+
'deep',
|
|
5
|
+
'diagnostic',
|
|
6
|
+
'auto',
|
|
7
|
+
] as const
|
|
8
|
+
|
|
9
|
+
export type ReasoningMode = (typeof REASONING_MODES)[number]
|
|
10
|
+
|
|
11
|
+
export type ReasoningModeSource =
|
|
12
|
+
| 'env'
|
|
13
|
+
| 'session'
|
|
14
|
+
| 'settings'
|
|
15
|
+
| 'legacy-env'
|
|
16
|
+
| 'default'
|
|
17
|
+
|
|
18
|
+
export type ResolvedReasoningPolicy = {
|
|
19
|
+
mode: ReasoningMode
|
|
20
|
+
source: ReasoningModeSource
|
|
21
|
+
enableThinking: boolean
|
|
22
|
+
parseReasoning: boolean
|
|
23
|
+
includeReasoning: boolean
|
|
24
|
+
persistThinking: boolean
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
type ReasoningEnv = Record<string, string | undefined>
|
|
28
|
+
|
|
29
|
+
export function isReasoningMode(value: unknown): value is ReasoningMode {
|
|
30
|
+
return (
|
|
31
|
+
typeof value === 'string' &&
|
|
32
|
+
(REASONING_MODES as readonly string[]).includes(value)
|
|
33
|
+
)
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export function parseReasoningMode(value: unknown): ReasoningMode | undefined {
|
|
37
|
+
if (value === undefined || value === null || value === '') return undefined
|
|
38
|
+
const normalized = String(value).toLowerCase()
|
|
39
|
+
return isReasoningMode(normalized) ? normalized : undefined
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export function getReasoningModeEnvOverride(
|
|
43
|
+
env: ReasoningEnv = process.env,
|
|
44
|
+
): ReasoningMode | undefined {
|
|
45
|
+
return parseReasoningMode(env.UMMAYA_K_EXAONE_REASONING_MODE)
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
export function getLegacyThinkingEnvMode(
|
|
49
|
+
env: ReasoningEnv = process.env,
|
|
50
|
+
): ReasoningMode | undefined {
|
|
51
|
+
const raw = env.UMMAYA_K_EXAONE_THINKING
|
|
52
|
+
if (raw === undefined) return undefined
|
|
53
|
+
const normalized = raw.toLowerCase()
|
|
54
|
+
if (normalized === '1' || normalized === 'true' || normalized === 'yes') {
|
|
55
|
+
return 'deep'
|
|
56
|
+
}
|
|
57
|
+
if (normalized === '0' || normalized === 'false' || normalized === 'no') {
|
|
58
|
+
return 'fast'
|
|
59
|
+
}
|
|
60
|
+
return undefined
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export function resolveKExaoneReasoningPolicy({
|
|
64
|
+
explicitSessionMode,
|
|
65
|
+
userSettingsMode,
|
|
66
|
+
env = process.env,
|
|
67
|
+
}: {
|
|
68
|
+
explicitSessionMode?: ReasoningMode
|
|
69
|
+
userSettingsMode?: ReasoningMode
|
|
70
|
+
env?: ReasoningEnv
|
|
71
|
+
} = {}): ResolvedReasoningPolicy {
|
|
72
|
+
const envMode = getReasoningModeEnvOverride(env)
|
|
73
|
+
if (envMode !== undefined) return policyFor(envMode, 'env')
|
|
74
|
+
if (explicitSessionMode !== undefined) {
|
|
75
|
+
return policyFor(explicitSessionMode, 'session')
|
|
76
|
+
}
|
|
77
|
+
if (userSettingsMode !== undefined) {
|
|
78
|
+
return policyFor(userSettingsMode, 'settings')
|
|
79
|
+
}
|
|
80
|
+
const legacyMode = getLegacyThinkingEnvMode(env)
|
|
81
|
+
if (legacyMode !== undefined) return policyFor(legacyMode, 'legacy-env')
|
|
82
|
+
return policyFor('balanced', 'default')
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
export function providerReasoningPayload(
|
|
86
|
+
policy: ResolvedReasoningPolicy,
|
|
87
|
+
): {
|
|
88
|
+
chat_template_kwargs: { enable_thinking: boolean }
|
|
89
|
+
parse_reasoning: boolean
|
|
90
|
+
include_reasoning: boolean
|
|
91
|
+
} {
|
|
92
|
+
return {
|
|
93
|
+
chat_template_kwargs: { enable_thinking: policy.enableThinking },
|
|
94
|
+
parse_reasoning: policy.parseReasoning,
|
|
95
|
+
include_reasoning: policy.includeReasoning,
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
export function getInitialReasoningModeSetting(): ReasoningMode | undefined {
|
|
100
|
+
return parseReasoningMode(
|
|
101
|
+
// Lazy require would avoid this dependency, but settings already imports
|
|
102
|
+
// this utility only for schema constants. Keep the read side cycle-free by
|
|
103
|
+
// requiring at call time.
|
|
104
|
+
// eslint-disable-next-line @typescript-eslint/no-require-imports
|
|
105
|
+
(require('./settings/settings.js') as typeof import('./settings/settings.js'))
|
|
106
|
+
.getInitialSettings().reasoningMode,
|
|
107
|
+
)
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
export function getReasoningModeDescription(mode: ReasoningMode): string {
|
|
111
|
+
switch (mode) {
|
|
112
|
+
case 'fast':
|
|
113
|
+
return 'latency-first answers with deterministic progress painting'
|
|
114
|
+
case 'balanced':
|
|
115
|
+
return 'default production policy with reasoning parsing but no raw trace'
|
|
116
|
+
case 'deep':
|
|
117
|
+
return 'provider thinking enabled and streamed when K-EXAONE emits it'
|
|
118
|
+
case 'diagnostic':
|
|
119
|
+
return 'deep provider thinking for local diagnostic inspection'
|
|
120
|
+
case 'auto':
|
|
121
|
+
return 'adaptive placeholder; currently resolves to the balanced payload'
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
function policyFor(
|
|
126
|
+
mode: ReasoningMode,
|
|
127
|
+
source: ReasoningModeSource,
|
|
128
|
+
): ResolvedReasoningPolicy {
|
|
129
|
+
const enableThinking = mode === 'deep' || mode === 'diagnostic'
|
|
130
|
+
return {
|
|
131
|
+
mode,
|
|
132
|
+
source,
|
|
133
|
+
enableThinking,
|
|
134
|
+
parseReasoning: true,
|
|
135
|
+
includeReasoning: enableThinking,
|
|
136
|
+
persistThinking: false,
|
|
137
|
+
}
|
|
138
|
+
}
|
|
@@ -2973,6 +2973,7 @@ export function handleMessageFromStream(
|
|
|
2973
2973
|
}))
|
|
2974
2974
|
}
|
|
2975
2975
|
}
|
|
2976
|
+
|
|
2976
2977
|
// Clear streaming text NOW so the render can switch displayedMessages
|
|
2977
2978
|
// from deferredMessages to messages in the same batch, making the
|
|
2978
2979
|
// transition from streaming text → final message atomic (no gap, no duplication).
|
|
@@ -88,3 +88,16 @@ export function getStreamingThinkingInsertIndex(renderableMessages: readonly Lay
|
|
|
88
88
|
}
|
|
89
89
|
return renderableMessages.length
|
|
90
90
|
}
|
|
91
|
+
|
|
92
|
+
export function insertStreamingThinkingLayoutMessage<T extends LayoutMessageLike>(
|
|
93
|
+
renderableMessages: readonly T[],
|
|
94
|
+
thinking: string | null | undefined,
|
|
95
|
+
): Array<T | StreamingThinkingLayoutMessage> {
|
|
96
|
+
if (!thinking) return [...renderableMessages]
|
|
97
|
+
const insertIndex = getStreamingThinkingInsertIndex(renderableMessages)
|
|
98
|
+
return [
|
|
99
|
+
...renderableMessages.slice(0, insertIndex),
|
|
100
|
+
createStreamingThinkingLayoutMessage(thinking),
|
|
101
|
+
...renderableMessages.slice(insertIndex),
|
|
102
|
+
]
|
|
103
|
+
}
|