Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix typo #10

Open
wants to merge 61 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
61 commits
Select commit Hold shift + click to select a range
2aacefa
Delete 4me.py
liteli1987gmail May 1, 2023
0028f06
Delete exnav.py
liteli1987gmail May 1, 2023
b230940
Delete nav.py
liteli1987gmail May 1, 2023
cb5a27f
Delete tomdx.py
liteli1987gmail May 1, 2023
ea79a1b
Update README.md
liteli1987gmail May 1, 2023
bb646d3
Merge branch 'main' of https://github.com/liteli1987gmail/langchainzh
liteli1987gmail May 1, 2023
f3ce083
feat: 删除py文件
liteli1987gmail May 1, 2023
d47936a
Update README.md
liteli1987gmail May 1, 2023
b285f46
feat: 翻译用例的第一级目录
liteli1987gmail May 3, 2023
f93c3c8
feat:新增modules模块下model页面
liteli1987gmail May 4, 2023
f45db50
Merge branch 'main' of https://github.com/liteli1987gmail/langchainzh
liteli1987gmail May 4, 2023
fc22ac1
feat: 新增’/pages/modules/models/llms‘下级文件夹
liteli1987gmail May 5, 2023
79a2665
feat: 删除错误占位符
liteli1987gmail May 5, 2023
ec62433
feat: 翻译”/modules/models/chat/“
liteli1987gmail May 5, 2023
29a9c74
feat: 翻译”./pages/modules/models/text_embedding“
liteli1987gmail May 5, 2023
4174a44
修改样式
liteli1987gmail May 5, 2023
3c2656a
删除错乱页面,翻译prompts模块
liteli1987gmail May 5, 2023
e93158d
feat: 翻译目录
liteli1987gmail May 5, 2023
a199252
自定义首页
liteli1987gmail May 6, 2023
0535f0a
翻译生态板块
liteli1987gmail May 6, 2023
8eea920
更新依赖
liteli1987gmail May 6, 2023
70df4cf
更新依赖
liteli1987gmail May 6, 2023
bfab87c
翻译三层目录
liteli1987gmail May 6, 2023
ff31933
delete
liteli1987gmail May 6, 2023
a7a0863
翻译模块
liteli1987gmail May 7, 2023
9a427f5
修复跳转链接
liteli1987gmail May 7, 2023
877ece8
增加入群二维码
liteli1987gmail May 8, 2023
e02327a
更换地址
liteli1987gmail May 8, 2023
24ec625
更换地址
liteli1987gmail May 8, 2023
c08389f
增加footer
liteli1987gmail May 8, 2023
c9529b6
图片
liteli1987gmail May 8, 2023
12901ea
图片address
liteli1987gmail May 8, 2023
5b60870
fix
liteli1987gmail May 12, 2023
0f58f22
add banner
liteli1987gmail May 14, 2023
c0ced25
修复未翻译到的
liteli1987gmail May 19, 2023
4bae68b
add code copy
liteli1987gmail May 23, 2023
df4c8af
代码可复制
liteli1987gmail May 23, 2023
86a8d50
增加代码统计注入
liteli1987gmail May 25, 2023
2791572
设置openai和milvus的链接
liteli1987gmail May 25, 2023
036bdaa
添加代码的颜色
liteli1987gmail May 26, 2023
4a8288f
全部加python代码颜色
liteli1987gmail May 26, 2023
988175a
修复遗漏翻译
liteli1987gmail May 30, 2023
1a4c1ae
修改head标签
liteli1987gmail May 30, 2023
d5db0cd
查漏补缺
liteli1987gmail May 30, 2023
0905462
修改首页标题
liteli1987gmail May 30, 2023
14318a7
新增链接pinecone
liteli1987gmail Jun 1, 2023
be6c805
修复404
liteli1987gmail Jun 9, 2023
37b0955
用户用例404页面
liteli1987gmail Jun 9, 2023
6ffd348
/modules/models/llms/integrations的链接跳转错误
liteli1987gmail Jun 9, 2023
c071d86
首页增加验证
liteli1987gmail Jun 9, 2023
d675d6b
修复首页跳转链接
liteli1987gmail Jun 9, 2023
553a3cf
增加网站icon标志
liteli1987gmail Jun 9, 2023
f2e6901
增加js版本链接
liteli1987gmail Jun 11, 2023
9c7aaa4
修复跳转问题
liteli1987gmail Jun 11, 2023
81f0a77
增加python.langchain.com.cn的跳转
liteli1987gmail Jun 16, 2023
8ea56d6
更新python仓库
liteli1987gmail Jun 21, 2023
5ee0d08
fix:内存页面-链接跳转404
liteli1987gmail Jul 2, 2023
2cd5e11
fix: 自定义代理的表述
liteli1987gmail Jul 2, 2023
27e1b19
fix parentheses or repeat typo
kt-cheng Oct 12, 2023
8afffec
add back mistake deletion
kt-cheng Oct 12, 2023
b4434bb
fix typo
kt-cheng Oct 13, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
77 changes: 0 additions & 77 deletions 4me.py

This file was deleted.

20 changes: 17 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
# Langchain中文网



Langchain中文网是Langchain的中文社区。

Langchain 是 Harrison Chase 的开源项目。
[Langchain](https://github.com/hwchase17/langchain) 。
Langchain 是 Harrison Chase 的开源项目[Langchain](https://github.com/hwchase17/langchain) 。

本项目将英文翻译为中文。版权所有归 Harrison Chase 所有。

Expand All @@ -14,6 +15,8 @@ Langchain中文网的目的是帮助中国人阅读 Langchain 的文档。
联系人:特美丽,微信号是 abc18601613801。




更多关于如何使用Langchain的信息,请参阅[官方文档](https://python.langchain.com)。

## 贡献指南
Expand All @@ -34,5 +37,16 @@ Langchain中文网的目的是帮助中国人阅读 Langchain 的文档。
Langchain 是 Harrison Chase 的开源项目,中文网仅做了翻译工作。一切版权归属Harrison Chase。


此外,我们欢迎任何形式的贡献,包括但不限于代码、文档、测试、警告、错误修复等等。


## CHANGELOG


2023年6月21日 更新文档到v0.0.206


2023年5月24日 增加代码颜色块,查漏补缺

此外,我们欢迎任何形式的贡献,包括但不限于代码、文档、测试、警告、错误修复等等。
这些页面报语法错误但是未能解决

31 changes: 31 additions & 0 deletions addcodelang.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
import os
import re

def process_markdown_lines(file_path):
with open(file_path, "r", encoding="utf-8") as file:
lines = file.readlines()

line_indices_to_change = []
for index, line in enumerate(lines):
if line.strip().startswith("```"):
line_indices_to_change.append(index)

# 删除偶数索引的项,只保留奇数索引的项
line_indices_to_change = line_indices_to_change[::2]

# 替换要修改的行
for index in line_indices_to_change:
lines[index] = "```python\n"

with open(file_path, "w", encoding="utf-8") as file:
file.writelines(lines)

# 您可以替换为 Markdown 文件或 Markdown 文件集所在的目录。
file_dir = "./pages/use_cases"
default_language = "python"

for root, dirs, files in os.walk(file_dir):
for file in files:
if file.endswith(".md"):
filepath = os.path.join(root, file)
process_markdown_lines(filepath)
69 changes: 69 additions & 0 deletions addpagetitle.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
import os
import re

def replace_extension(folder_path):
# 递归遍历文件夹
for root, dirs, files in os.walk(folder_path):
for filename in files:
if filename.endswith('.md'):
file_path = os.path.join(root, filename)
print(file_path)

# 将文件名 .md 替换为 .mdx
new_filename = re.sub('\.md$', '.mdx', filename)
new_file_path = os.path.join(root, new_filename)

# 读取文件并插入 JavaScript 代码
with open(file_path, 'r',encoding='utf-8') as f_in:
file_content = f_in.read()

with open(new_file_path, 'w',encoding='utf-8') as f_out:
# 插入 JavaScript 代码
js_code = """
import Head from 'next/head'

<Head>
<meta name="baidu-site-verification" content="codeva-vVWLPfYJJm" />
<script>
{
`(function() {
var _hmt = _hmt || [];
(function() {
var hm = document.createElement("script");
hm.src = "https://hm.baidu.com/hm.js?e60fb290e204e04c5cb6f79b0ac1e697";
var s = document.getElementsByTagName("script")[0];
s.parentNode.insertBefore(hm, s);
})();
})();`
}
</script>
</Head>

![LangChain](https://pica.zhimg.com/50/v2-56e8bbb52aa271012541c1fe1ceb11a2_r.gif)"""

# 如果新文件不存在,则在新文件中写入 JavaScript 代码和原始文件内容
if not os.path.exists(new_file_path):
f_out.write(js_code + '\n\n' + file_content)
# 如果新文件已经存在,则只写入 JavaScript 代码和原始文件内容
else:
with open(new_file_path, 'r',encoding='utf-8') as f:
existing_content = f.read()
f_out.write(js_code + '\n\n' + existing_content + '\n\n' + file_content)

print(f'Renamed {filename} to {new_filename}')


def delete_md_files(folder_path):
# 递归遍历文件夹
for root, dirs, files in os.walk(folder_path):
for filename in files:
if filename.endswith('.md'):
file_path = os.path.join(root, filename)

# 删除文件
os.remove(file_path)



# replace_extension('./pages/use_cases/')
delete_md_files('./pages/use_cases/')
Binary file added components/quncode.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
70 changes: 0 additions & 70 deletions exnav.py

This file was deleted.

19 changes: 0 additions & 19 deletions nav.py

This file was deleted.

3 changes: 2 additions & 1 deletion next.config.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
const withNextra = require('nextra')({
theme: 'nextra-theme-docs',
themeConfig: './theme.config.tsx',
defaultShowCopyCode: true
})

// defaultShowCopyCode: true
module.exports = withNextra()
Loading