{"record":{"id":"cd83e86b386e5aa6","repo":"chroma-core/chroma","slug":"model-name-cannot-be-updated-cd83e8","errorCode":null,"errorMessage":"Model name cannot be updated","messagePattern":"Model name cannot be updated","errorType":"validation","errorClass":"ChromaValueError","httpStatus":null,"severity":"error","filePath":"clients/new-js/packages/ai-embeddings/perplexity/src/index.ts","lineNumber":98,"sourceCode":"  public defaultSpace(): EmbeddingFunctionSpace {\n    return \"cosine\";\n  }\n\n  public supportedSpaces(): EmbeddingFunctionSpace[] {\n    return [\"cosine\", \"l2\", \"ip\"];\n  }\n\n  public getConfig(): PerplexityConfig {\n    return {\n      api_key_env_var: this.apiKeyEnvVar,\n      model_name: this.modelName,\n      dimensions: this.dimensions,\n    };\n  }\n\n  public validateConfigUpdate(newConfig: Record<string, unknown>): void {\n    if (this.getConfig().model_name !== newConfig.model_name) {\n      throw new ChromaValueError(\"Model name cannot be updated\");\n    }\n  }\n\n  public static validateConfig(config: PerplexityConfig): void {\n    validateConfigSchema(config, NAME);\n  }\n}\n\nregisterEmbeddingFunction(NAME, PerplexityEmbeddingFunction);","sourceCodeStart":80,"sourceCodeEnd":107,"githubUrl":"https://github.com/chroma-core/chroma/blob/aecdd12c8a891610db8653630b066b32ceb678b5/clients/new-js/packages/ai-embeddings/perplexity/src/index.ts#L80-L107","documentation":"Error \"Model name cannot be updated\" thrown in chroma-core/chroma.","triggerScenarios":"Thrown at clients/new-js/packages/ai-embeddings/perplexity/src/index.ts:98 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"aecdd12c8a891610db8653630b066b32ceb678b5","analyzedAt":"2026-08-16T21:53:27.228Z","schemaVersion":2},"datasetVersion":"2026-08-16T23:17:17.608Z"}