MCPcopy Create free account
hub / github.com/anomalyco/opencode / summarize

Function summarize

packages/opencode/src/cli/cmd/github.handler.ts:878–887  ·  view source on GitHub ↗
(response: string)

Source from the content-addressed store, hash-verified

876 }
877
878 async function summarize(response: string) {
879 try {
880 return await chat(`Summarize the following in less than 40 characters:\n\n${response}`)
881 } catch {
882 const title = issueEvent
883 ? issueEvent.issue.title
884 : (payload as PullRequestReviewCommentEvent).pull_request.title
885 return `Fix issue: ${title}`
886 }
887 }
888
889 async function chat(message: string, files: PromptFiles = []) {
890 console.log("Sending message to opencode...")

Callers 1

github.handler.tsFile · 0.70

Calls 1

chatFunction · 0.70

Tested by

no test coverage detected