import type { ExtensionAPI } from "@earendil-works/pi-coding-agent"; import { Type } from "typebox"; import type { HabitDetail, HabitId, HabitStreak, HabitSummaryWithStreak } from "../domain/habit"; import type { HabitService } from "../services/habit-service"; interface HabitListToolDetails { kind: "habit_list"; habits: HabitSummaryWithStreak[]; total: number; empty: boolean; } interface HabitShowToolParams { habitId: HabitId; } interface HabitShowToolDetails { kind: "habit_show"; habitId: HabitId; found: boolean; habit?: HabitDetail; streak?: HabitStreak; } interface HabitReadToolDependencies { getHabitService: () => Promise; } declare const createHabitListToolDefinition: ({ getHabitService }: HabitReadToolDependencies) => { name: string; label: string; description: string; promptSnippet: string; promptGuidelines: string[]; parameters: Type.TObject<{}>; execute(_toolCallId: string, _params: Record): Promise<{ content: { type: "text"; text: string; }[]; details: HabitListToolDetails; }>; }; declare const createHabitShowToolDefinition: ({ getHabitService }: HabitReadToolDependencies) => { name: string; label: string; description: string; promptSnippet: string; promptGuidelines: string[]; parameters: Type.TObject<{ habitId: Type.TString; }>; execute(_toolCallId: string, params: HabitShowToolParams): Promise<{ content: { type: "text"; text: string; }[]; details: HabitShowToolDetails; }>; }; declare const registerHabitReadTools: (pi: Pick, dependencies: HabitReadToolDependencies) => void; declare const formatHabitListContent: (details: HabitListToolDetails) => string; declare const formatStreakLabel: (streak: HabitStreak | null) => string; declare const formatTodayLabel: (streak: HabitStreak | null) => string; declare const formatHabitShowContent: (habit: HabitDetail, streak: HabitStreak | null) => string; export type { HabitListToolDetails, HabitReadToolDependencies, HabitShowToolDetails }; export { createHabitListToolDefinition, createHabitShowToolDefinition, formatHabitListContent, formatHabitShowContent, formatStreakLabel, formatTodayLabel, registerHabitReadTools, };