pxiaoer commited on
Commit
63d3256
1 Parent(s): e2e2cfd
Files changed (6) hide show
  1. .gitattributes +0 -35
  2. .pre-commit-config.yaml +0 -55
  3. .vscode/settings.json +0 -21
  4. README.md +1 -1
  5. app.py +2 -2
  6. papers.py +5 -5
.gitattributes DELETED
@@ -1,35 +0,0 @@
1
- *.7z filter=lfs diff=lfs merge=lfs -text
2
- *.arrow filter=lfs diff=lfs merge=lfs -text
3
- *.bin filter=lfs diff=lfs merge=lfs -text
4
- *.bz2 filter=lfs diff=lfs merge=lfs -text
5
- *.ckpt filter=lfs diff=lfs merge=lfs -text
6
- *.ftz filter=lfs diff=lfs merge=lfs -text
7
- *.gz filter=lfs diff=lfs merge=lfs -text
8
- *.h5 filter=lfs diff=lfs merge=lfs -text
9
- *.joblib filter=lfs diff=lfs merge=lfs -text
10
- *.lfs.* filter=lfs diff=lfs merge=lfs -text
11
- *.mlmodel filter=lfs diff=lfs merge=lfs -text
12
- *.model filter=lfs diff=lfs merge=lfs -text
13
- *.msgpack filter=lfs diff=lfs merge=lfs -text
14
- *.npy filter=lfs diff=lfs merge=lfs -text
15
- *.npz filter=lfs diff=lfs merge=lfs -text
16
- *.onnx filter=lfs diff=lfs merge=lfs -text
17
- *.ot filter=lfs diff=lfs merge=lfs -text
18
- *.parquet filter=lfs diff=lfs merge=lfs -text
19
- *.pb filter=lfs diff=lfs merge=lfs -text
20
- *.pickle filter=lfs diff=lfs merge=lfs -text
21
- *.pkl filter=lfs diff=lfs merge=lfs -text
22
- *.pt filter=lfs diff=lfs merge=lfs -text
23
- *.pth filter=lfs diff=lfs merge=lfs -text
24
- *.rar filter=lfs diff=lfs merge=lfs -text
25
- *.safetensors filter=lfs diff=lfs merge=lfs -text
26
- saved_model/**/* filter=lfs diff=lfs merge=lfs -text
27
- *.tar.* filter=lfs diff=lfs merge=lfs -text
28
- *.tar filter=lfs diff=lfs merge=lfs -text
29
- *.tflite filter=lfs diff=lfs merge=lfs -text
30
- *.tgz filter=lfs diff=lfs merge=lfs -text
31
- *.wasm filter=lfs diff=lfs merge=lfs -text
32
- *.xz filter=lfs diff=lfs merge=lfs -text
33
- *.zip filter=lfs diff=lfs merge=lfs -text
34
- *.zst filter=lfs diff=lfs merge=lfs -text
35
- *tfevents* filter=lfs diff=lfs merge=lfs -text
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
.pre-commit-config.yaml DELETED
@@ -1,55 +0,0 @@
1
- repos:
2
- - repo: https://github.com/pre-commit/pre-commit-hooks
3
- rev: v4.5.0
4
- hooks:
5
- - id: check-executables-have-shebangs
6
- - id: check-json
7
- - id: check-merge-conflict
8
- - id: check-shebang-scripts-are-executable
9
- - id: check-toml
10
- - id: check-yaml
11
- - id: end-of-file-fixer
12
- - id: mixed-line-ending
13
- args: ["--fix=lf"]
14
- - id: requirements-txt-fixer
15
- - id: trailing-whitespace
16
- - repo: https://github.com/myint/docformatter
17
- rev: v1.7.5
18
- hooks:
19
- - id: docformatter
20
- args: ["--in-place"]
21
- - repo: https://github.com/pycqa/isort
22
- rev: 5.12.0
23
- hooks:
24
- - id: isort
25
- args: ["--profile", "black"]
26
- - repo: https://github.com/pre-commit/mirrors-mypy
27
- rev: v1.6.1
28
- hooks:
29
- - id: mypy
30
- args: ["--ignore-missing-imports"]
31
- additional_dependencies:
32
- ["types-python-slugify", "types-requests", "types-PyYAML"]
33
- - repo: https://github.com/psf/black
34
- rev: 23.10.0
35
- hooks:
36
- - id: black
37
- language_version: python3.10
38
- args: ["--line-length", "119"]
39
- - repo: https://github.com/kynan/nbstripout
40
- rev: 0.6.1
41
- hooks:
42
- - id: nbstripout
43
- args:
44
- [
45
- "--extra-keys",
46
- "metadata.interpreter metadata.kernelspec cell.metadata.pycharm",
47
- ]
48
- - repo: https://github.com/nbQA-dev/nbQA
49
- rev: 1.7.0
50
- hooks:
51
- - id: nbqa-black
52
- - id: nbqa-pyupgrade
53
- args: ["--py37-plus"]
54
- - id: nbqa-isort
55
- args: ["--float-to-top"]
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
.vscode/settings.json DELETED
@@ -1,21 +0,0 @@
1
- {
2
- "[python]": {
3
- "editor.defaultFormatter": "ms-python.black-formatter",
4
- "editor.formatOnType": true,
5
- "editor.codeActionsOnSave": {
6
- "source.organizeImports": true
7
- }
8
- },
9
- "black-formatter.args": [
10
- "--line-length=119"
11
- ],
12
- "isort.args": ["--profile", "black"],
13
- "flake8.args": [
14
- "--max-line-length=119"
15
- ],
16
- "ruff.args": [
17
- "--line-length=119"
18
- ],
19
- "editor.formatOnSave": true,
20
- "files.insertFinalNewline": true
21
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
README.md CHANGED
@@ -1,5 +1,5 @@
1
  ---
2
- title: Daily Papers
3
  emoji: 📊
4
  colorFrom: pink
5
  colorTo: pink
 
1
  ---
2
+ title: 每日最新论文
3
  emoji: 📊
4
  colorFrom: pink
5
  colorTo: pink
app.py CHANGED
@@ -7,7 +7,7 @@ import gradio as gr
7
  from papers import PaperList, get_df
8
  from update_scheduler import UpdateScheduler
9
 
10
- DESCRIPTION = "# [Daily Papers](https://huggingface.co/papers)"
11
 
12
  paper_list = PaperList(get_df("papers.csv"))
13
 
@@ -31,4 +31,4 @@ with gr.Blocks(css="style.css") as demo:
31
  )
32
 
33
  if __name__ == "__main__":
34
- demo.queue(api_open=False).launch()
 
7
  from papers import PaperList, get_df
8
  from update_scheduler import UpdateScheduler
9
 
10
+ DESCRIPTION = "# [每日最新论文](https://huggingface.co/papers)"
11
 
12
  paper_list = PaperList(get_df("papers.csv"))
13
 
 
31
  )
32
 
33
  if __name__ == "__main__":
34
+ demo.queue(api_open=False).launch( share= True)
papers.py CHANGED
@@ -69,7 +69,7 @@ class Prettifier:
69
  for _, row in df.iterrows():
70
  new_row = dict(row) | {
71
  "date": Prettifier.create_link(row.date, f"https://huggingface.co/papers?date={row.date}"),
72
- "paper_page": Prettifier.create_link(row.arxiv_id, row.paper_page),
73
  "github": self.get_github_link(row.github),
74
  }
75
  new_rows.append(new_row)
@@ -78,11 +78,11 @@ class Prettifier:
78
 
79
  class PaperList:
80
  COLUMN_INFO = [
81
- ["date", "markdown"],
82
- ["paper_page", "markdown"],
83
- ["title", "str"],
84
  ["github", "markdown"],
85
- ["upvotes", "number"],
86
  ]
87
 
88
  def __init__(self, df: pd.DataFrame):
 
69
  for _, row in df.iterrows():
70
  new_row = dict(row) | {
71
  "date": Prettifier.create_link(row.date, f"https://huggingface.co/papers?date={row.date}"),
72
+ "arxiv": "https://arxiv.org/abs/"+row.arxiv_id,
73
  "github": self.get_github_link(row.github),
74
  }
75
  new_rows.append(new_row)
 
78
 
79
  class PaperList:
80
  COLUMN_INFO = [
81
+ ["日期", "markdown"],
82
+ ["arxiv", "markdown"],
83
+ ["标题", "str"],
84
  ["github", "markdown"],
85
+ ["点赞", "number"],
86
  ]
87
 
88
  def __init__(self, df: pd.DataFrame):