Skip to content

refactor(sync): remove unused model metadata logic in kilo provider#3235

Open
levdad wants to merge 8 commits into
anomalyco:devfrom
levdad:kilo-sync-cleanup
Open

refactor(sync): remove unused model metadata logic in kilo provider#3235
levdad wants to merge 8 commits into
anomalyco:devfrom
levdad:kilo-sync-cleanup

Conversation

@levdad

@levdad levdad commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

Remove unused file system imports, constants, and helper functions (modelMetadataExists, baseModelOmit, baseModelOverrides, etc.) that were previously used for managing model metadata via local TOML files. This cleans up the Kilo sync provider by removing dead code and unnecessary dependencies on node:fs and node:path.

based on the review of #2997 comment

Remove unused file system imports, constants, and helper functions
(`modelMetadataExists`, `baseModelOmit`, `baseModelOverrides`, etc.)
that were previously used for managing model metadata via local TOML
files. This cleans up the Kilo sync provider by removing dead code
and unnecessary dependencies on `node:fs` and `node:path`.
@github-actions

Copy link
Copy Markdown
Contributor

No actionable findings.

levdad added 4 commits July 14, 2026 13:21
Apply consistent code formatting to the Kilo sync provider, including
multi-line type imports, Zod schema definitions, and improved line
wrapping for complex conditional expressions and function calls.
Ensure that `apiDescription` is explicitly converted to `null` if it is
falsy before falling back to `describeModel`. This prevents potential
issues with truthiness checks and ensures consistent object structure
when the description is missing.
Update the type assertion for `orderedEfforts` in the Kilo provider to
use a conditional type check against `SyncedFullModel`. This ensures
that the `values` property strictly adheres to the expected type
definition of the reasoning options, preventing type mismatches
during synchronization.
@github-actions

Copy link
Copy Markdown
Contributor

No actionable findings.

@levdad

levdad commented Jul 14, 2026

Copy link
Copy Markdown
Contributor Author

Added a fix for the error when the api returned an empty description for a model, like the error in GitHub Action.

@rekram1-node can you have a look at this?

levdad added 3 commits July 15, 2026 10:28
…hinking variants

Update Kilo and OpenRouter providers to recognize and correctly process
model IDs ending in `:discounted` and `:thinking`. This ensures these
specialized model variants are properly mapped to their canonical base
models during the synchronization process.
Adjust the priority of model description resolution to ensure that
`apiDescription` is preferred over `existing.description`, while
maintaining the fallback to `describeModel` if neither is available.
@github-actions

Copy link
Copy Markdown
Contributor

No actionable findings.

@levdad

levdad commented Jul 15, 2026

Copy link
Copy Markdown
Contributor Author

Reordering the description logic to prioritize the provider/API description.
This ensures we surface much richer details about how the provider uses the models (such as training data), especially regarding discounted or free models.

Verified in 61cf5c5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant