400 Bison模型调优已被弃用。请迁移到Gemini调优

我已经为这个错误挣扎了一天。我试图在colab上使用VertexAI运行Kubeflow管道进行模型微调。这是我的代码

# Get the current date for model namingdate = datetime.datetime.now().strftime("%Y-%m-%d")MODEL_NAME = f"qa-model-{date}"# Pipeline argumentspipeline_arguments = {    "model_display_name": MODEL_NAME,    "location": REGION,    "project": PROJECT_ID,    "large_model_reference": "gemini-1.0-pro-002",  # Model reference for question answering    "train_steps": TRAINING_STEPS,    "dataset_uri": TRAINING_DATA_URI,    "evaluation_interval": EVALUATION_INTERVAL,    "evaluation_data_uri": EVALUATION_DATA_URI,}# Define the pipeline template path for model tuningtemplate_path = "https://us-kfp.pkg.dev/ml-pipeline/large-language-model-pipelines/tune-large-model/v2.0.0"# Create a pipeline job for fine-tuning the modeljob = aiplatform.PipelineJob(    template_path=template_path,    display_name="fine-tune-gemini-qa",    parameter_values=pipeline_arguments,    location=REGION,    pipeline_root="gs://zeinab-llmops-vertexai/pipeline_root",  # GCS path for storing pipeline artifacts    enable_caching=True)# Submit the pipeline jobjob.submit()

显然,我试图使用Gemini,但却得到了以下错误,该错误抱怨使用了Bison并建议我使用Gemini!!

_InactiveRpcError: <_InactiveRpcError of RPC that terminated with:    status = StatusCode.FAILED_PRECONDITION    details = "Bison model tuning is deprecated. Please migrate to Gemini tuning."    debug_error_string = "UNKNOWN:Error received from peer ipv4:172.217.203.95:443 {created_time:"2025-02-28T06:30:14.731451386+00:00", grpc_status:9, grpc_message:"Bison model tuning is deprecated. Please migrate to Gemini tuning."}">The above exception was the direct cause of the following exception:FailedPrecondition                        Traceback (most recent call last)/usr/local/lib/python3.11/dist-packages/google/api_core/grpc_helpers.py in error_remapped_callable(*args, **kwargs)     76             return callable_(*args, **kwargs)     77         except grpc.RpcError as exc:---> 78             raise exceptions.from_grpc_error(exc) from exc     79      80     return error_remapped_callableFailedPrecondition: 400 Bison model tuning is deprecated. Please migrate to Gemini tuning.

我有一个付费的GCP账户,信用额度充足,并且在项目中拥有Vertex AI用户角色。任何帮助我都会非常感激!


回答:

你可以在这里找到如何调优Gemini: https://cloud.google.com/vertex-ai/generative-ai/docs/models/gemini-use-supervised-tuning

你使用的SDK语法确实是来自已弃用的Bison

Related Posts

使用LSTM在Python中预测未来值

这段代码可以预测指定股票的当前日期之前的值,但不能预测…

如何在gensim的word2vec模型中查找双词组的相似性

我有一个word2vec模型,假设我使用的是googl…

dask_xgboost.predict 可以工作但无法显示 – 数据必须是一维的

我试图使用 XGBoost 创建模型。 看起来我成功地…

ML Tuning – Cross Validation in Spark

我在https://spark.apache.org/…

如何在React JS中使用fetch从REST API获取预测

我正在开发一个应用程序,其中Flask REST AP…

如何分析ML.NET中多类分类预测得分数组?

我在ML.NET中创建了一个多类分类项目。该项目可以对…

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注