# langchain-examples **Repository Path**: nightowl7/langchain-examples ## Basic Information - **Project Name**: langchain-examples - **Description**: langchain学习使用 - **Primary Language**: Python - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2024-05-23 - **Last Updated**: 2024-06-03 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # llm-store #### 介绍 langchain agent+灵积模型服务根据git提交记录的备注来生成周报 #### 软件架构 软件架构说明 - python3.8 - langchain - 灵积模型服务 qwen-14b-chat #### 使用教程 1. 安装所需要的包 ```bash pip install -r .\requirements.txt ``` 2. 前往灵积模型服务创建ApiKey ps:qwen-14b-chat 目前有100万token的免费额度 https://dashscope.console.aliyun.com/apiKey 3. 设置ApiKey [weekly_generation.py](python%2Fweekly_generation.py) 34行 ```python llm = ChatOpenAI( api_key='<灵积的ApiKey>', base_url="https://dashscope.aliyuncs.com/compatible-mode/v1", model="qwen-14b-chat" ) ``` 4. 设置git项目的文件夹路径[weekly_generation.py](python%2Fweekly_generation.py) 31行 ```python git_dir = "" ``` 5. 如果你是多人开发一个项目建议改一下git的命令[get_git_mark.py](python%2Ftools%2Fget_git_mark.py) 32行 ```python #执行git命令获取备注 这里面如果是多人开发的话建议加上自己的git的用户名 command = ["git", "log", "--since='1 week ago'", "--pretty=format:\"%s\""] ``` 6. 开始推理执行这个文件即可[weekly_generation.zip](python%2Fweekly_generation.zip)