AIGC学习笔记(6)——AI大模型开发工程师

文章目录

AI大模型开发工程师

005 OpenAI大模型案例实践

1 AI 翻译助手需求分析

项目起源
市场价格和市场前景
基于大模型的翻译软件
核心功能设计

2 AI 翻译助手架构设计

架构设计
代码结构设计

3 AI 翻译助手核心功能

文档解析
文档操作
python 复制代码
## 导入操作word文档和PDF文档的依赖库
! pip install pdfplumber
PDF文档操作
  • 读取文档
python 复制代码
import pdfplumber
pdf = pdfplumber.open("测试文档/test1.pdf")
pages = pdf.pages

# 读取所有页面的文本内容
with pdfplumber.open("测试文档/test1.pdf") as pdf:
    for page in pdf.pages:
        print(page.extract_text())

# 获取单页文本(保留布局)
text = pages[0].extract_text(layout=True)
text
表格操作
python 复制代码
table = pages[1].extract_table()
table

import pandas as pd

df = pd.DataFrame(table[1:], columns=table[0])

print(df)
图片操作
python 复制代码
pages[2].images

img = pages[2].images[0]
bbox = (img["x0"], img["top"], img["x1"], img["bottom"])
cropped_page = pages[2].crop(bbox)
cropped_page.to_image()
Prompt封装
  • 方式一
  • 方式二:使用 LangChain

4 AI 翻译助手代码落地

5 AI 翻译助手项目总结

相关推荐
安思派Anspire15 分钟前
Github上全球趋势榜第一的产品,背后是Anspire Search的搜索硬实力!
aigc·openai
与虾牵手1 小时前
OpenClaw 请求超时 llm request timed out 怎么解决?3 种方案实测,附完整排查流程
aigc·ai编程
老王熬夜敲代码1 小时前
Planner
langchain
用户5191495848452 小时前
Rust命令注入漏洞演示工具 (CVE-2024-24576)
人工智能·aigc
wentianen2 小时前
当 AI 开始自己写代码,我更在意的是它到底做了什么
aigc·openai·ai编程
花千树-0103 小时前
Claude Code / Codex 架构推测 + 可实现版本设计(从0到1复刻一个Agent系统)
人工智能·ai·架构·aigc·ai编程
青梅煮酒与君饮3 小时前
浅谈大模型、Agent、Function Calling、MCP、Skill、Subagent、Langchain、Workflow
人工智能·python·语言模型·langchain·llama
是Smoky呢3 小时前
springAI+向量数据库(SimpleVectorStore)+RAG深度理解
spring·aigc·ai编程
liu****4 小时前
LangChain-AI应用开发框架(一)
c++·python·langchain·本地部署大模型