{"record":{"id":"9d223e28841e6ec2","repo":"weaviate/weaviate","slug":"model-s-is-only-available-in-version-001","errorCode":null,"errorMessage":"model %s is only available in version 001","messagePattern":"model (.+?) is only available in version 001","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"modules/text2vec-openai/ent/class_settings.go","lineNumber":245,"sourceCode":"\t\t// no restrictions\n\t\treturn nil\n\t}\n\n\tif version == \"002\" {\n\t\t// only ada/davinci 002\n\t\tif model != \"ada\" && model != \"davinci\" {\n\t\t\treturn fmt.Errorf(\"unsupported version %s\", version)\n\t\t}\n\t}\n\n\tif version == \"003\" && model != \"davinci\" {\n\t\t// only davinci 003\n\t\treturn fmt.Errorf(\"unsupported version %s\", version)\n\t}\n\n\tif version != \"002\" && version != \"003\" {\n\t\t// all other fallback\n\t\treturn fmt.Errorf(\"model %s is only available in version 001\", model)\n\t}\n\n\tif docType != \"text\" {\n\t\treturn fmt.Errorf(\"ada-002 no longer distinguishes between text/code, use 'text' for all use cases\")\n\t}\n\n\treturn nil\n}\n\nfunc (cs *classSettings) validateAzureConfig(resourceName, deploymentId, apiVersion string) error {\n\tif (resourceName == \"\" && deploymentId != \"\") || (resourceName != \"\" && deploymentId == \"\") {\n\t\treturn fmt.Errorf(\"both resourceName and deploymentId must be provided\")\n\t}\n\tif !basesettings.ValidateSetting(apiVersion, availableApiVersions) {\n\t\treturn errors.Errorf(\"wrong Azure OpenAI apiVersion setting, available api versions are: %v\", availableApiVersions)\n\t}\n\treturn nil\n}","sourceCodeStart":227,"sourceCodeEnd":263,"githubUrl":"https://github.com/weaviate/weaviate/blob/75aa4b6d11f8818305aafd4440b4e32794f7ca04/modules/text2vec-openai/ent/class_settings.go#L227-L263","documentation":"text2vec-openai validates model/version pairs at class-creation time. Once a model is on version 002 or 003 (ada), Weaviate no longer permits falling back to version 001 for that model; the only supported way to use such a model is version 001, and using any other version with a model that only exists in 001 triggers this error. It is a static configuration check before any OpenAI request is made.","triggerScenarios":"Setting moduleConfig text2vec-openai to a model that only exists as a 001 embedding model while specifying version 002/003 — e.g. {model: \"babbage\", version: \"002\"} — or {model: \"sage\", version: \"002\"} where only 001 is valid.","commonSituations":"Upgrading a config template and bumping 'version' globally for all classes while some classes use 001-only models; misunderstanding that version is per-model, not global.","solutions":["Remove the 'version' field (or set it to \"001\") for models that only exist in version 001.","If you need 002/003, switch the model to one that supports those versions (e.g. text-embedding-ada-002 / davinci).","Update the module/text2vec-openai version if your Weaviate release predates the model you want, since availability is enforced in class_settings.go."],"exampleFix":"// before\n\"moduleConfig\": { \"text2vec-openai\": { \"model\": \"babbage\", \"version\": \"002\" } }\n// after\n\"moduleConfig\": { \"text2vec-openai\": { \"model\": \"babbage\", \"version\": \"001\" } }","handlingStrategy":"validation","validationCode":"function check001OnlyModel(model, version) {\n  if ([\"babbage\", \"curie\"].includes(model) && version !== \"001\") {\n    throw new Error(`model ${model} is only available in version 001`);\n  }\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Never bump 'version' globally across classes using different models","Map model -> allowed versions explicitly in tooling","Dry-run class creation against a test Weaviate instance before production schema changes"],"tags":["weaviate","text2vec-openai","configuration","schema-validation"],"backgroundTag":"unsupported-model-version","analyzedSha":"75aa4b6d11f8818305aafd4440b4e32794f7ca04","analyzedAt":"2026-09-04T14:58:20.392Z","contentChangedAt":"2026-09-04T14:58:20.392Z","schemaVersion":2},"datasetVersion":"2026-09-11T21:17:09.523Z"}