/** * @fractary/faber - WorkManager * * Main entry point for work tracking operations. * Supports GitHub Issues, Jira, and Linear. */ import { WorkConfig, Issue, IssueCreateOptions, IssueUpdateOptions, IssueFilters, IssueUpsertResult, ClassifyResult, Comment, Label, Milestone, MilestoneCreateOptions, FaberContext } from '../common/types'; import { ListCommentsOptions } from './types'; /** * WorkManager - Unified work tracking across platforms * * @example * ```typescript * const work = new WorkManager(); * const issue = await work.fetchIssue(123); * await work.createComment(123, 'Implementation complete'); * ``` */ export declare class WorkManager { private provider; private config; constructor(config?: WorkConfig); /** * Load work configuration from project * * Transforms the YAML handler-based config format into the flat WorkConfig * that the rest of the class expects. */ private loadConfig; /** * Create the appropriate provider based on config */ private createProvider; /** * Get the current platform */ getPlatform(): string; /** * Create a new issue */ createIssue(options: IssueCreateOptions): Promise; /** * Find an existing matching issue and comment on it, or create a new one. * * When `updateExisting` is false (or not set), behaves identically to `createIssue`. * When `updateExisting` is true, searches for an open issue matching the title and labels, * then adds the body as a comment instead of creating a duplicate. */ findOrCreateIssue(options: IssueCreateOptions): Promise; /** * Fetch an issue by ID */ fetchIssue(issueId: string | number): Promise; /** * Update an existing issue */ updateIssue(issueId: string | number, options: IssueUpdateOptions): Promise; /** * Close an issue */ closeIssue(issueId: string | number): Promise; /** * Reopen a closed issue */ reopenIssue(issueId: string | number): Promise; /** * Search for issues */ searchIssues(query: string, filters?: IssueFilters): Promise; /** * Assign an issue to a user */ assignIssue(issueId: string | number, assignee: string): Promise; /** * Unassign an issue */ unassignIssue(issueId: string | number): Promise; /** * Create a comment on an issue */ createComment(issueId: string | number, body: string, faberContext?: FaberContext, repo?: string): Promise; /** * List comments on an issue */ listComments(issueId: string | number, options?: ListCommentsOptions): Promise; /** * Add labels to an issue */ addLabels(issueId: string | number, labels: string[]): Promise; /** * Remove labels from an issue */ removeLabels(issueId: string | number, labels: string[]): Promise; /** * Set labels on an issue (replaces existing) */ setLabels(issueId: string | number, labels: string[]): Promise; /** * List all labels (or labels on an issue) */ listLabels(issueId?: string | number): Promise; /** * Create a new milestone */ createMilestone(options: MilestoneCreateOptions): Promise; /** * Set milestone on an issue */ setMilestone(issueId: string | number, milestone: string): Promise; /** * Remove milestone from an issue */ removeMilestone(issueId: string | number): Promise; /** * List all milestones */ listMilestones(state?: 'open' | 'closed' | 'all'): Promise; /** * Label-based scoring configuration for classification */ private static readonly LABEL_SCORES; /** * Keyword groups for title-based classification */ private static readonly KEYWORDS; /** * Classify the type of work based on issue metadata with confidence scoring * * Uses a multi-signal approach: * 1. Labels (highest priority) - direct mapping with high confidence * 2. Title keywords - pattern matching with moderate confidence * * @param issue - The issue to classify * @returns Classification result with work type, confidence score, and signals */ classifyWorkType(issue: Issue): ClassifyResult; } //# sourceMappingURL=manager.d.ts.map