Skip to content

infer.py无非正常推理 #1

Open
@evanweiguohua

Description

UserWarning: You have modified the pretrained model configuration to control generation. This is a deprecated strategy to control generation and will be removed soon, in a future version. Please use a generation configuration file (see https://huggingface.co/docs/transformers/main_classes/text_generation )
warnings.warn(
input 请提供三个管理时间的建议。
output

官方示例:
from transformers import AutoTokenizer, AutoModelForCausalLM
tokenizer = AutoTokenizer.from_pretrained("/home/dev/model/internlm-chat-7b-8k", trust_remote_code=True)

model = AutoModelForCausalLM.from_pretrained("/home/dev/model/internlm-chat-7b-8k", trust_remote_code=True).cuda()
model = model.eval()
response, history = model.chat(tokenizer, "请提供三个管理时间的建议。", history=[])
print(response)

  1. 制定优先级:将任务按照紧急程度和重要性排序,然后逐一完成。2. 时间分配:合理分配时间,根据任务的重要性和紧急程度,合理分配时间,避免过度压缩时间导致效率低下。3. 时间规划:制定长期和短期计划,合理规划时间,避免时间浪费,提高效率。

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions