Index

A B C F G H I L O S T V 
All Classes and Interfaces|All Packages

A

applyDiff(List<String>, String) - Static method in class io.codemodder.plugins.llm.LLMDiffs
Applies a diff in unified format to target.

B

BinaryThreatRisk - Enum Class in io.codemodder.plugins.llm
The possible outcomes of a binary risk analysis -- "high" or "low".

C

configure() - Method in class io.codemodder.plugins.llm.LLMServiceModule
 
countTokens(List<ChatMessage>) - Static method in class io.codemodder.plugins.llm.Tokens
Estimates the number of tokens the messages will consume when passed to the gpt-3.5-turbo-0613 or gpt-4-0613 models.
createChatCompletion(ChatCompletionRequest) - Method in class io.codemodder.plugins.llm.OpenAIService
 

F

FileDescription - Interface in io.codemodder.plugins.llm
Provides a set of useful methods to simplify working with the files.
formatLinesWithLineNumbers() - Method in interface io.codemodder.plugins.llm.FileDescription
Return the file as a single string, but with each line prefixed with the line number, starting with 1.
from(Path) - Static method in interface io.codemodder.plugins.llm.FileDescription
 

G

getCharset() - Method in interface io.codemodder.plugins.llm.FileDescription
Returns the file's charset.
getFileName() - Method in interface io.codemodder.plugins.llm.FileDescription
Returns the file name.
getFixPrompt() - Method in class io.codemodder.plugins.llm.SarifToLLMForBinaryVerificationAndFixingCodemod
Instructs the LLM on how to fix the threat.
getLines() - Method in interface io.codemodder.plugins.llm.FileDescription
Returns the file as a list of lines.
getLineSeparator() - Method in interface io.codemodder.plugins.llm.FileDescription
Returns the file's preferred line separator by locating the first line separator and assuming "\n" if none are found.
getModules(Path, List<Class<? extends CodeChanger>>, List<RuleSarif>) - Method in class io.codemodder.plugins.llm.LLMProvider
 
getThreatPrompt(CodemodInvocationContext, List<Result>) - Method in class io.codemodder.plugins.llm.SarifToLLMForBinaryVerificationAndFixingCodemod
Instructs the LLM on how to assess the risk of the threat.

H

HIGH - Enum constant in enum class io.codemodder.plugins.llm.BinaryThreatRisk
 

I

io.codemodder.plugins.llm - package io.codemodder.plugins.llm
 
isPatchExpected(Patch<String>) - Method in class io.codemodder.plugins.llm.SarifToLLMForBinaryVerificationAndFixingCodemod
Returns whether the patch returned by the LLM is within the expectations of this codemod.

L

LLMDiffs - Class in io.codemodder.plugins.llm
Utilities for working with diff patches returned by an LLM.
LLMProvider - Class in io.codemodder.plugins.llm
Provides LLM-related functionality to codemods.
LLMProvider() - Constructor for class io.codemodder.plugins.llm.LLMProvider
 
LLMServiceModule - Class in io.codemodder.plugins.llm
Provides configured LLM services.
LLMServiceModule() - Constructor for class io.codemodder.plugins.llm.LLMServiceModule
 
LOW - Enum constant in enum class io.codemodder.plugins.llm.BinaryThreatRisk
 

O

onFileFound(CodemodInvocationContext, List<Result>) - Method in class io.codemodder.plugins.llm.SarifToLLMForBinaryVerificationAndFixingCodemod
 
OpenAIService - Class in io.codemodder.plugins.llm
A custom service class to call the OpenAiApi, since the out-of-the box OpenAiService does not support automatic retries.
OpenAIService(String) - Constructor for class io.codemodder.plugins.llm.OpenAIService
 

S

SarifToLLMForBinaryVerificationAndFixingCodemod - Class in io.codemodder.plugins.llm
An extension of SarifPluginRawFileChanger that uses large language models (LLMs) to more deeply analyze and then fix the files found by the static analysis tool.
SarifToLLMForBinaryVerificationAndFixingCodemod(RuleSarif, OpenAIService) - Constructor for class io.codemodder.plugins.llm.SarifToLLMForBinaryVerificationAndFixingCodemod
 

T

Tokens - Class in io.codemodder.plugins.llm
A set of utilities around LLM tokens.

V

valueOf(String) - Static method in enum class io.codemodder.plugins.llm.BinaryThreatRisk
Returns the enum constant of this class with the specified name.
values() - Static method in enum class io.codemodder.plugins.llm.BinaryThreatRisk
Returns an array containing the constants of this enum class, in the order they are declared.
A B C F G H I L O S T V 
All Classes and Interfaces|All Packages