Add support for specifying response file location #30
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request introduces a new feature for handling custom response file paths in the AI inference action, along with improvements to error handling and test coverage. The changes include updates to the
README.md
documentation, theaction.yml
file, the main action logic insrc/main.ts
, and the test suite in__tests__/main.test.ts
.New Feature: Custom Response File Paths
README.md
explaining how to use a custom response file path (response-file
) in workflows.response-file
input inaction.yml
to specify the file path where the model's response should be saved.getResponseFilePath
helper function insrc/main.ts
to handle custom response file paths, ensuring directories are created if necessary. Updated the main logic to use this function. [1] [2]Improved Error Handling
src/main.ts
to gracefully manage bothError
and non-Error
exceptions, providing clearer feedback in workflow runs. [1] [2]Test Suite Enhancements
__tests__/main.test.ts
to verify:Error
and non-Error
exceptions.fs.writeFileSync
andfs.mkdirSync
to support testing file system operations. [1] [2]These changes collectively improve the flexibility, reliability, and testability of the action.