Commit 7c444e8
Support extract use CPU and optimize some codes. (#707)
* Support extract use CPU and optimize some codes.
* Fix workspace path.
* Support configurable extract and verify timeouts with CPU/GPU defaults.
- GraphNetAgent: add extract_timeout and verify_timeout parameters
- parallel_extract: add --extract-timeout and --verify-timeout CLI args
- Default timeouts differ by device:
GPU: extract=1000s, verify=300s
CPU: extract=2000s, verify=600s
- Fix typo: os.envion -> os.environ
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Add --use-llm flag to parallel_extract for configurable LLM retry.
- New CLI arg --use-llm (default: true) controls llm_retry in GraphNetAgent
- Pass llm_retry through worker_fn and _resolve_config
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* Refactor extract_sample return to ExtractionStatus enum and split success rates.
- Introduce ExtractionStatus(str, Enum): OK, VERIFY_FAILED, EXTRACT_FAILED, ERROR
- GraphNetAgent.extract_sample() now returns ExtractionStatus instead of bool
- parallel_extract tracks and prints both overall and extraction-only success rates
- Per-GPU/Worker summary also shows both rates
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>1 parent 540d57f commit 7c444e8
5 files changed
Lines changed: 267 additions & 119 deletions
File tree
- graph_net/agent
- graph_extractor
- sample_verifier
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
Lines changed: 3 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
25 | | - | |
| 25 | + | |
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | | - | |
| 29 | + | |
30 | 30 | | |
31 | 31 | | |
32 | | - | |
| 32 | + | |
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| 5 | + | |
5 | 6 | | |
6 | 7 | | |
7 | 8 | | |
| |||
23 | 24 | | |
24 | 25 | | |
25 | 26 | | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
26 | 36 | | |
27 | 37 | | |
28 | 38 | | |
| |||
31 | 41 | | |
32 | 42 | | |
33 | 43 | | |
| 44 | + | |
| 45 | + | |
34 | 46 | | |
35 | 47 | | |
36 | 48 | | |
37 | 49 | | |
38 | 50 | | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
44 | 60 | | |
45 | 61 | | |
46 | 62 | | |
| |||
63 | 79 | | |
64 | 80 | | |
65 | 81 | | |
66 | | - | |
| 82 | + | |
| 83 | + | |
67 | 84 | | |
68 | | - | |
| 85 | + | |
69 | 86 | | |
70 | 87 | | |
71 | 88 | | |
72 | 89 | | |
73 | | - | |
| 90 | + | |
74 | 91 | | |
75 | 92 | | |
76 | 93 | | |
| |||
82 | 99 | | |
83 | 100 | | |
84 | 101 | | |
85 | | - | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
86 | 106 | | |
87 | 107 | | |
88 | 108 | | |
| |||
104 | 124 | | |
105 | 125 | | |
106 | 126 | | |
107 | | - | |
| 127 | + | |
108 | 128 | | |
109 | 129 | | |
110 | 130 | | |
111 | | - | |
| 131 | + | |
112 | 132 | | |
113 | 133 | | |
114 | | - | |
| 134 | + | |
115 | 135 | | |
116 | | - | |
| 136 | + | |
117 | 137 | | |
118 | | - | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
119 | 142 | | |
120 | 143 | | |
121 | | - | |
| 144 | + | |
122 | 145 | | |
123 | 146 | | |
124 | 147 | | |
| |||
0 commit comments