Skip to content

Commit e57e4b2

Browse files
gracefullightgithub-actions[bot]
authored andcommitted
chore(deps): update oh-my-agent skills
1 parent 703b147 commit e57e4b2

110 files changed

Lines changed: 4086 additions & 246 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
"$schema": "./agent-variant.schema.json",
3+
"vendor": "opencode",
4+
"destDir": ".opencode/agents",
5+
"modelDefault": "opencode-go/deepseek-v4-flash",
6+
"toolsDefault": [],
7+
"protocolPath": ".agents/skills/_shared/runtime/execution-protocols/opencode.md",
8+
"agents": {
9+
"backend-engineer": {},
10+
"frontend-engineer": {},
11+
"db-engineer": {},
12+
"debug-investigator": {},
13+
"architecture-reviewer": {},
14+
"tf-infra-engineer": {},
15+
"mobile-engineer": {},
16+
"pm-planner": {},
17+
"qa-reviewer": {},
18+
"docs-curator": {},
19+
"refactor-engineer": {},
20+
"research-explorer": {}
21+
}
22+
}

.agents/config/defaults.yaml

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -55,21 +55,6 @@ runtime_profiles:
5555
tf-infra: { model: "openai/gpt-5.5", effort: "high" }
5656
explore: { model: "openai/gpt-5.4-mini", effort: "low" }
5757

58-
gemini:
59-
description: "Gemini — Google AI Pro"
60-
agent_defaults:
61-
orchestrator: { model: "google/gemini-3-flash" }
62-
architecture: { model: "google/gemini-3.1-pro-preview", thinking: true }
63-
qa: { model: "google/gemini-3-flash", thinking: true }
64-
pm: { model: "google/gemini-3-flash" }
65-
backend: { model: "google/gemini-3-flash", thinking: true }
66-
frontend: { model: "google/gemini-3-flash", thinking: true }
67-
mobile: { model: "google/gemini-3-flash", thinking: true }
68-
db: { model: "google/gemini-3-flash", thinking: true }
69-
debug: { model: "google/gemini-3-flash", thinking: true }
70-
tf-infra: { model: "google/gemini-3-flash", thinking: true }
71-
explore: { model: "google/gemini-3.1-flash-lite" }
72-
7358
mixed:
7459
description: "Mixed — role-optimal vendors per agent (Claude for orchestration/QA/PM, Codex for impl, Gemini for explore)"
7560
agent_defaults:

.agents/hooks/core/agentmemory-client.ts

Lines changed: 57 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,15 +142,63 @@ export interface RecalledFact {
142142

143143
interface SearchResult {
144144
score?: number;
145+
timestamp?: unknown;
146+
created_at?: unknown;
145147
observation?: {
146148
narrative?: unknown;
147149
facts?: unknown;
148150
title?: unknown;
149151
type?: unknown;
152+
timestamp?: unknown;
153+
created_at?: unknown;
150154
};
151155
}
152156

153-
function parseSearchResults(body: string, k: number): RecalledFact[] {
157+
/**
158+
* Recall TTL: facts older than this many days are dropped from the snapshot so
159+
* stale, long-resolved decisions stop rehydrating every boundary. Default 30
160+
* days; set `OMA_RECALL_MAX_AGE_DAYS=0` (or a non-positive value) to disable.
161+
* Returns the max age in ms, or null when disabled.
162+
*/
163+
function recallMaxAgeMs(): number | null {
164+
const raw = process.env.OMA_RECALL_MAX_AGE_DAYS;
165+
const days = raw === undefined ? 30 : Number(raw);
166+
if (!Number.isFinite(days) || days <= 0) return null;
167+
return days * 24 * 60 * 60 * 1000;
168+
}
169+
170+
/**
171+
* Best-effort timestamp extraction from a search result. AgentMemory's response
172+
* envelope is not contractually fixed across versions, so several candidate
173+
* field names / locations are probed. Numeric epoch seconds are normalised to
174+
* ms. Returns null when no parseable timestamp is present — callers then keep
175+
* the fact (TTL filtering is fail-open, never dropping facts of unknown age).
176+
*/
177+
function extractTimestampMs(entry: SearchResult): number | null {
178+
const obs = entry.observation ?? {};
179+
const candidates: unknown[] = [
180+
obs.timestamp,
181+
obs.created_at,
182+
entry.timestamp,
183+
entry.created_at,
184+
];
185+
for (const candidate of candidates) {
186+
if (typeof candidate === "number" && Number.isFinite(candidate)) {
187+
return candidate < 1e12 ? candidate * 1000 : candidate;
188+
}
189+
if (typeof candidate === "string" && candidate.trim()) {
190+
const parsed = Date.parse(candidate);
191+
if (Number.isFinite(parsed)) return parsed;
192+
}
193+
}
194+
return null;
195+
}
196+
197+
export function parseSearchResults(
198+
body: string,
199+
k: number,
200+
nowMs: number = Date.now(),
201+
): RecalledFact[] {
154202
let parsed: { results?: unknown };
155203
try {
156204
parsed = JSON.parse(body) as { results?: unknown };
@@ -164,12 +212,20 @@ function parseSearchResults(body: string, k: number): RecalledFact[] {
164212
return Number.isFinite(raw) ? raw : 1;
165213
})();
166214

215+
const maxAgeMs = recallMaxAgeMs();
216+
const cutoffMs = maxAgeMs === null ? null : nowMs - maxAgeMs;
217+
167218
const facts: RecalledFact[] = [];
168219
for (const entry of parsed.results as SearchResult[]) {
169220
const score = typeof entry.score === "number" ? entry.score : 0;
170221
// Raw `/observe` envelopes score near-zero (~0.006); enriched facts score
171222
// in the single digits. Drop the noise floor so the snapshot stays useful.
172223
if (score < minScore) continue;
224+
// TTL: drop facts older than the cutoff (fail-open on unknown age).
225+
if (cutoffMs !== null) {
226+
const tsMs = extractTimestampMs(entry);
227+
if (tsMs !== null && tsMs < cutoffMs) continue;
228+
}
173229
const obs = entry.observation ?? {};
174230
const narrative =
175231
typeof obs.narrative === "string" && obs.narrative.trim()

.agents/hooks/core/triggers.json

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3033,6 +3033,54 @@
30333033
"会议转录"
30343034
]
30353035
}
3036+
},
3037+
"oma-refactor": {
3038+
"keywords": {
3039+
"*": ["oma-refactor"],
3040+
"en": [
3041+
"refactor this",
3042+
"refactoring plan",
3043+
"extract class",
3044+
"extract method",
3045+
"reduce complexity",
3046+
"measure complexity",
3047+
"code smell",
3048+
"technical debt",
3049+
"characterization test",
3050+
"hotspot analysis",
3051+
"split this class",
3052+
"clean up this code"
3053+
],
3054+
"ko": [
3055+
"리팩토링",
3056+
"리팩터링",
3057+
"복잡도 줄여",
3058+
"복잡도 측정",
3059+
"코드 스멜",
3060+
"기술 부채",
3061+
"클래스 분리",
3062+
"메서드 추출",
3063+
"코드 정리해줘"
3064+
],
3065+
"ja": [
3066+
"リファクタリング",
3067+
"複雑度を下げ",
3068+
"複雑度を測定",
3069+
"コードスメル",
3070+
"技術的負債",
3071+
"クラスを分割",
3072+
"メソッド抽出"
3073+
],
3074+
"zh": [
3075+
"重构",
3076+
"降低复杂度",
3077+
"测量复杂度",
3078+
"代码异味",
3079+
"技术债",
3080+
"拆分类",
3081+
"提取方法"
3082+
]
3083+
}
30363084
}
30373085
},
30383086
"informationalPatterns": {

.agents/hooks/variants/claude.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,19 +9,19 @@
99
"UserPromptSubmit": [
1010
{
1111
"hook": "keyword-detector.ts",
12-
"timeout": 5
12+
"timeout": 2
1313
},
1414
{
1515
"hook": "state-boundary.ts",
16-
"timeout": 5
16+
"timeout": 4
1717
},
1818
{
1919
"hook": "skill-injector.ts",
20-
"timeout": 3
20+
"timeout": 2
2121
},
2222
{
2323
"hook": "serena-primer.ts",
24-
"timeout": 3
24+
"timeout": 2
2525
}
2626
],
2727
"PreToolUse": {

0 commit comments

Comments
 (0)