Compare commits

..
Author SHA1 Message Date
Novice 986b75a5c0 fix: agent parallel wrong 2025-02-11 09:23:07 +08:00
Yeuoly f6472e8709 Merge branch 'plugins/beta' into dev/plugin-deploy 2025-02-10 21:13:59 +08:00
YeuolyandGitHub 50cfb7c9ec fix: allow variable message to be any (#13494) 2025-02-10 21:13:28 +08:00
JoelandGitHub 8281c688ca fix: iteration open parallel not show iteration detail (#13476) 2025-02-10 16:05:05 +08:00
Yi XiaoandGitHub ad9d6eb5f4 fix app detail panel merge issues (#13460) 2025-02-10 14:24:48 +08:00
JzoNg b0a8dec59e Merge branch 'tp' into dev/plugin-deploy 2025-02-10 12:44:53 +08:00
JzoNg ae800c21dd chore: fix DSL crash 2025-02-10 12:41:54 +08:00
JzoNg e149775616 use mixed type for string 2025-02-10 12:29:16 +08:00
JzoNg e8eab14658 checklist for tool 2025-02-10 12:29:16 +08:00
JzoNg 45db7d9cd4 hide params outside 2025-02-10 12:29:16 +08:00
JzoNg d8779b0da2 support variable for string 2025-02-10 12:29:16 +08:00
JzoNg 5d7400c8bb support variable for number, select, file 2025-02-10 12:29:16 +08:00
zxhlyhandJzoNg 6d36f2d239 fix: crash 2025-02-10 12:29:16 +08:00
JzoNg 8ac6bc0b5a tool setting support variable 2025-02-10 12:29:16 +08:00
Yi 27f2b2050d Merge branch 'fix/app-detail-panel-merge-issue' into dev/plugin-deploy 2025-02-10 12:01:57 +08:00
Yi d53282bb44 fix app detail panel merge issues 2025-02-10 11:55:20 +08:00
zxhlyhandGitHub aa3dc9002c fix: workflow chat preview (#13455) 2025-02-10 11:15:56 +08:00
JzoNg 82ead2735b Merge branch 'tp' into dev/plugin-deploy 2025-02-08 22:12:34 +08:00
JzoNg 27185eb98b use mixed type for string 2025-02-08 22:07:28 +08:00
JzoNg e06dc48472 checklist for tool 2025-02-08 21:57:23 +08:00
JzoNg 9f013d6590 hide params outside 2025-02-08 21:57:23 +08:00
JzoNg d51bd90394 support variable for string 2025-02-08 21:57:23 +08:00
JzoNg 91b89d755e support variable for number, select, file 2025-02-08 21:57:23 +08:00
zxhlyh 1409c81e76 fix: crash 2025-02-08 21:09:27 +08:00
+85 4a43e165fb Plugin/merge main 20250208 (#13414)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
Signed-off-by: -LAN- <laipz8200@outlook.com>
Signed-off-by: xhe <xw897002528@gmail.com>
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: kurokobo <kuro664@gmail.com>
Co-authored-by: Hiroshi Fujita <fujita-h@users.noreply.github.com>
Co-authored-by: NFish <douxc512@gmail.com>
Co-authored-by: Gen Sato <52241300+halogen22@users.noreply.github.com>
Co-authored-by: eux <euxuuu@gmail.com>
Co-authored-by: huangzhuo1949 <167434202+huangzhuo1949@users.noreply.github.com>
Co-authored-by: huangzhuo <huangzhuo1@xiaomi.com>
Co-authored-by: lotsik <lotsik@mail.ru>
Co-authored-by: crazywoola <100913391+crazywoola@users.noreply.github.com>
Co-authored-by: Wu Tianwei <30284043+WTW0313@users.noreply.github.com>
Co-authored-by: nite-knite <nkCoding@gmail.com>
Co-authored-by: Jyong <76649700+JohnJyong@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: gakkiyomi <gakkiyomi@aliyun.com>
Co-authored-by: CN-P5 <heibai2006@gmail.com>
Co-authored-by: CN-P5 <heibai2006@qq.com>
Co-authored-by: Chuehnone <1897025+chuehnone@users.noreply.github.com>
Co-authored-by: yihong <zouzou0208@gmail.com>
Co-authored-by: Kevin9703 <51311316+Kevin9703@users.noreply.github.com>
Co-authored-by: -LAN- <laipz8200@outlook.com>
Co-authored-by: Boris Feld <lothiraldan@gmail.com>
Co-authored-by: mbo <himabo@gmail.com>
Co-authored-by: mabo <mabo@aeyes.ai>
Co-authored-by: Warren Chen <warren.chen830@gmail.com>
Co-authored-by: KVOJJJin <jzongcode@gmail.com>
Co-authored-by: JzoNgKVO <27049666+JzoNgKVO@users.noreply.github.com>
Co-authored-by: jiandanfeng <chenjh3@wangsu.com>
Co-authored-by: zhu-an <70234959+xhdd123321@users.noreply.github.com>
Co-authored-by: zhaoqingyu.1075 <zhaoqingyu.1075@bytedance.com>
Co-authored-by: 海狸大師 <86974027+yenslife@users.noreply.github.com>
Co-authored-by: Xu Song <xusong.vip@gmail.com>
Co-authored-by: rayshaw001 <396301947@163.com>
Co-authored-by: Ding Jiatong <dingjiatong@gmail.com>
Co-authored-by: Bowen Liang <liangbowen@gf.com.cn>
Co-authored-by: JasonVV <jasonwangiii@outlook.com>
Co-authored-by: le0zh <newlight@qq.com>
Co-authored-by: zhuxinliang <zhuxinliang@didiglobal.com>
Co-authored-by: k-zaku <zaku99@outlook.jp>
Co-authored-by: Joel <iamjoel007@gmail.com>
Co-authored-by: luckylhb90 <luckylhb90@gmail.com>
Co-authored-by: hobo.l <hobo.l@binance.com>
Co-authored-by: jiangbo721 <365065261@qq.com>
Co-authored-by: 刘江波 <jiangbo721@163.com>
Co-authored-by: Shun Miyazawa <34241526+miya@users.noreply.github.com>
Co-authored-by: EricPan <30651140+Egfly@users.noreply.github.com>
Co-authored-by: crazywoola <427733928@qq.com>
Co-authored-by: zxhlyh <jasonapring2015@outlook.com>
Co-authored-by: sino <sino2322@gmail.com>
Co-authored-by: Jhvcc <37662342+Jhvcc@users.noreply.github.com>
Co-authored-by: lowell <lowell.hu@zkteco.in>
Co-authored-by: Ademílson Tonato <ademilsonft@outlook.com>
Co-authored-by: Ademílson Tonato <ademilson.tonato@refurbed.com>
Co-authored-by: IWAI, Masaharu <iwaim.sub@gmail.com>
Co-authored-by: Yueh-Po Peng (Yabi) <94939112+y10ab1@users.noreply.github.com>
Co-authored-by: 非法操作 <hjlarry@163.com>
Co-authored-by: Jason <ggbbddjm@gmail.com>
Co-authored-by: Xin Zhang <sjhpzx@gmail.com>
Co-authored-by: yjc980121 <3898524+yjc980121@users.noreply.github.com>
Co-authored-by: heyszt <36215648+hieheihei@users.noreply.github.com>
Co-authored-by: Abdullah AlOsaimi <osaimiacc@gmail.com>
Co-authored-by: Abdullah AlOsaimi <189027247+osaimi@users.noreply.github.com>
Co-authored-by: Yingchun Lai <laiyingchun@apache.org>
Co-authored-by: Hash Brown <hi@xzd.me>
Co-authored-by: zuodongxu <192560071+zuodongxu@users.noreply.github.com>
Co-authored-by: Masashi Tomooka <tmokmss@users.noreply.github.com>
Co-authored-by: aplio <ryo.091219@gmail.com>
Co-authored-by: Obada Khalili <54270856+obadakhalili@users.noreply.github.com>
Co-authored-by: Nam Vu <zuzoovn@gmail.com>
Co-authored-by: Kei YAMAZAKI <1715090+kei-yamazaki@users.noreply.github.com>
Co-authored-by: TechnoHouse <13776377+deephbz@users.noreply.github.com>
Co-authored-by: Riddhimaan-Senapati <114703025+Riddhimaan-Senapati@users.noreply.github.com>
Co-authored-by: MaFee921 <31881301+2284730142@users.noreply.github.com>
Co-authored-by: te-chan <t-nakanome@sakura-is.co.jp>
Co-authored-by: HQidea <HQidea@users.noreply.github.com>
Co-authored-by: Joshbly <36315710+Joshbly@users.noreply.github.com>
Co-authored-by: xhe <xw897002528@gmail.com>
Co-authored-by: weiwenyan-dev <154779315+weiwenyan-dev@users.noreply.github.com>
Co-authored-by: ex_wenyan.wei <ex_wenyan.wei@tcl.com>
Co-authored-by: engchina <12236799+engchina@users.noreply.github.com>
Co-authored-by: engchina <atjapan2015@gmail.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: 呆萌闷油瓶 <253605712@qq.com>
Co-authored-by: Kemal <kemalmeler@outlook.com>
Co-authored-by: Lazy_Frog <4590648+lazyFrogLOL@users.noreply.github.com>
Co-authored-by: Novice Lee <novicelee@NoviPro.local>
Co-authored-by: Yi Xiao <54782454+YIXIAO0@users.noreply.github.com>
Co-authored-by: Steven sun <98230804+Tuyohai@users.noreply.github.com>
Co-authored-by: steven <sunzwj@digitalchina.com>
Co-authored-by: Kalo Chin <91766386+fdb02983rhy@users.noreply.github.com>
Co-authored-by: Katy Tao <34019945+KatyTao@users.noreply.github.com>
Co-authored-by: depy <42985524+h4ckdepy@users.noreply.github.com>
Co-authored-by: 胡春东 <gycm520@gmail.com>
Co-authored-by: Junjie.M <118170653@qq.com>
2025-02-08 19:12:36 +08:00
JzoNg 26838eb42a tool setting support variable 2025-02-08 17:11:24 +08:00
Yeuoly f0098d17ed Merge branch 'fix/import-old-dsl' into dev/plugin-deploy 2025-02-08 16:58:55 +08:00
Yeuoly 54e9748240 fix: supporting return current identifier 2025-02-08 16:02:10 +08:00
Yeuoly 48111a7f71 Merge branch 'fix/import-old-dsl' into dev/plugin-deploy 2025-02-08 15:29:16 +08:00
Yeuoly cdd610f94f fix: handle jina/gemini/siliconflow 2025-02-08 15:26:51 +08:00
Yeuoly daf11f4af1 Merge branch 'fix/import-old-dsl' into dev/plugin-deploy 2025-02-08 14:54:28 +08:00
Yeuoly e3a81f09a9 fix: ruff 2025-02-08 14:54:02 +08:00
Yeuoly 8d5a8f0153 fix: using latest plugin as the dep of DSL under 0.1.15 2025-02-08 14:53:43 +08:00
zxhlyhandGitHub 4d25b598f9 fix: template app check dependency (#13389) 2025-02-08 14:11:20 +08:00
JoelandGitHub 3e9c3d0bb7 fix: install installed plugin problem (#13384) 2025-02-08 11:31:55 +08:00
zxhlyhandGitHub fec3bb4469 fix: models sort in model page (#13334) 2025-02-07 17:30:04 +08:00
JyongandGitHub d4a09805a3 improve preview document tokenizer (#13328) 2025-02-07 16:08:25 +08:00
zxhlyhandGitHub 7e1d9894fb fix: plugins task permission (#13330) 2025-02-07 16:02:12 +08:00
zxhlyhandGitHub a8a8a5513c fix: app check dependency (#13320) 2025-02-07 14:04:49 +08:00
Nite KniteandGitHub 470e72c820 chore: bump katex version and tweak UI copy (#13280) 2025-02-07 14:02:57 +08:00
Novice Lee 95eeb7b0d1 feat: agent node custom tool input 2025-02-07 11:02:31 +08:00
Yeuoly 933b6abc13 fix: ci 2025-02-06 18:36:14 +08:00
Yeuoly 1097bf314a Merge branch 'plugins/beta' into dev/plugin-deploy 2025-02-06 18:30:49 +08:00
Boris PolonskyandGitHub beebba0340 Unify plugin endpoint configuration for api and worker: An alternative solution to PR #13214 (#13239) 2025-02-06 11:29:37 +08:00
YeuolyandGitHub 4e27d82d68 improve: remove docker-legacy (#13236) 2025-02-05 20:28:02 +08:00
Boris PolonskyandGitHub cdeaf3f70b Fix ruff linting error caused by api/models/dataset.py (#13221) 2025-02-05 17:45:23 +08:00
YeuolyandGitHub 24839bb3e1 fix: mismatches dependencies in dockerfile (#13220) 2025-02-05 17:00:26 +08:00
KVOJJJinandGitHub 1650dbfbb1 Fix: merge error of tracing and web app setting modal (#13219) 2025-02-05 16:16:28 +08:00
JoelandGitHub fd11817044 fix: select input not show save value (#13218) 2025-02-05 16:13:40 +08:00
Wu TianweiandGitHub 6642fc6012 fix: fix fallback route logic (#13199) 2025-02-05 14:38:36 +08:00
KVOJJJinandGitHub 2710242982 Feat: feature and log dark mode (#13208) 2025-02-05 13:58:19 +08:00
kurokoboandGitHub 1de84fdda0 fix: correct env vars for docker deployment (#13055) 2025-01-27 11:19:29 +08:00
Wu TianweiandWTW0313 4920821270 feat: docx image preview (#13057) 2025-01-26 16:08:58 +08:00
JyongandWTW0313 a16c729d5a add sign-content (#13050) 2025-01-26 16:05:19 +08:00
Wu TianweiandGitHub 3befbc1d68 feat: docx image preview (#13057) 2025-01-26 15:12:05 +08:00
JyongandGitHub 62c413aca5 add sign-content (#13050) 2025-01-26 10:58:47 +08:00
JoelandGitHub 6887b501b8 fix: can choose selected tools and show tool name instead of label (#13025) 2025-01-24 22:34:09 +08:00
非法操作andGitHub f93bf131ab fix(1.0): explore market page empty (#13017) 2025-01-24 18:43:56 +08:00
非法操作andGitHub ef1f429437 fix(1.0): update github plugin 404 (#13014) 2025-01-24 18:42:14 +08:00
KVOJJJinandGitHub c966bf1474 Feat: dark mode of app configure (#13010) 2025-01-24 14:16:35 +08:00
+42 899df30bf6 Plugin/merge main to plugin/beta 20250122 (#12962)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
Signed-off-by: -LAN- <laipz8200@outlook.com>
Co-authored-by: kurokobo <kuro664@gmail.com>
Co-authored-by: Hiroshi Fujita <fujita-h@users.noreply.github.com>
Co-authored-by: NFish <douxc512@gmail.com>
Co-authored-by: Gen Sato <52241300+halogen22@users.noreply.github.com>
Co-authored-by: eux <euxuuu@gmail.com>
Co-authored-by: huangzhuo1949 <167434202+huangzhuo1949@users.noreply.github.com>
Co-authored-by: huangzhuo <huangzhuo1@xiaomi.com>
Co-authored-by: lotsik <lotsik@mail.ru>
Co-authored-by: crazywoola <100913391+crazywoola@users.noreply.github.com>
Co-authored-by: Wu Tianwei <30284043+WTW0313@users.noreply.github.com>
Co-authored-by: nite-knite <nkCoding@gmail.com>
Co-authored-by: Jyong <76649700+JohnJyong@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: gakkiyomi <gakkiyomi@aliyun.com>
Co-authored-by: CN-P5 <heibai2006@gmail.com>
Co-authored-by: CN-P5 <heibai2006@qq.com>
Co-authored-by: Chuehnone <1897025+chuehnone@users.noreply.github.com>
Co-authored-by: yihong <zouzou0208@gmail.com>
Co-authored-by: Kevin9703 <51311316+Kevin9703@users.noreply.github.com>
Co-authored-by: -LAN- <laipz8200@outlook.com>
Co-authored-by: Boris Feld <lothiraldan@gmail.com>
Co-authored-by: mbo <himabo@gmail.com>
Co-authored-by: mabo <mabo@aeyes.ai>
Co-authored-by: Warren Chen <warren.chen830@gmail.com>
Co-authored-by: KVOJJJin <jzongcode@gmail.com>
Co-authored-by: JzoNgKVO <27049666+JzoNgKVO@users.noreply.github.com>
Co-authored-by: jiandanfeng <chenjh3@wangsu.com>
Co-authored-by: zhu-an <70234959+xhdd123321@users.noreply.github.com>
Co-authored-by: zhaoqingyu.1075 <zhaoqingyu.1075@bytedance.com>
Co-authored-by: 海狸大師 <86974027+yenslife@users.noreply.github.com>
Co-authored-by: Xu Song <xusong.vip@gmail.com>
Co-authored-by: rayshaw001 <396301947@163.com>
Co-authored-by: Ding Jiatong <dingjiatong@gmail.com>
Co-authored-by: Bowen Liang <liangbowen@gf.com.cn>
Co-authored-by: JasonVV <jasonwangiii@outlook.com>
Co-authored-by: le0zh <newlight@qq.com>
Co-authored-by: zhuxinliang <zhuxinliang@didiglobal.com>
Co-authored-by: k-zaku <zaku99@outlook.jp>
Co-authored-by: Joel <iamjoel007@gmail.com>
Co-authored-by: luckylhb90 <luckylhb90@gmail.com>
Co-authored-by: hobo.l <hobo.l@binance.com>
Co-authored-by: jiangbo721 <365065261@qq.com>
Co-authored-by: 刘江波 <jiangbo721@163.com>
Co-authored-by: Shun Miyazawa <34241526+miya@users.noreply.github.com>
Co-authored-by: EricPan <30651140+Egfly@users.noreply.github.com>
Co-authored-by: crazywoola <427733928@qq.com>
Co-authored-by: zxhlyh <jasonapring2015@outlook.com>
Co-authored-by: sino <sino2322@gmail.com>
Co-authored-by: Jhvcc <37662342+Jhvcc@users.noreply.github.com>
Co-authored-by: lowell <lowell.hu@zkteco.in>
2025-01-23 14:48:16 +08:00
zxhlyhandGitHub 8d8d3e3f2f fix: plugin search api url (#12977) 2025-01-23 14:25:24 +08:00
非法操作andGitHub 5f0fa38ec6 fix(1.0): invoke llm raise error (#12753) 2025-01-22 16:46:35 +08:00
YeuolyandGitHub cc1fe70d34 fix: add adapter for datasets update checking (#12939) 2025-01-22 15:40:06 +08:00
Hiroki NagaiandGitHub 15ee1e11be fix: 500 error in Notion integration API (#12934) 2025-01-22 14:38:01 +08:00
JoelandGitHub c8b4a76530 fix: agent node output vars error (#12931) 2025-01-22 13:33:27 +08:00
Novice Lee 4765728cef feat: add agent node stream output 2025-01-22 09:59:40 +08:00
YeuolyandGitHub 6ee4eba86b fix: change default PLUGIN_DAEMON_URL to http://localhost:5002 (#12915) 2025-01-21 22:30:24 +08:00
非法操作andGitHub 357d2e8be8 fix(1.0): add cross-env to pnpm run dev (#12600) 2025-01-21 19:51:32 +08:00
kurokoboandGitHub b5accda3fe fix: correct validation for agent node which is invoked before publishing the app (#12805) 2025-01-21 10:07:25 +08:00
非法操作andGitHub de4752a16b fix(1.0): unexpected error raise (#12812) 2025-01-21 10:04:56 +08:00
非法操作andGitHub 60427f1adf chore(1.0): improve some environment variables (#12814) 2025-01-21 10:04:46 +08:00
非法操作andGitHub 1a313c868d fix(1.0): sometimes add tool raise error (#12821) 2025-01-21 10:04:05 +08:00
YeuolyandGitHub 0b32b1988f fix: missing tenant_id in get_signed_file_url_for_plugin (#12734) 2025-01-14 19:39:21 +08:00
KVOJJJinandGitHub e56c051d97 Fix: tool card info (#12726) 2025-01-14 16:10:00 +08:00
Novice Lee 5063f27916 Merge branch 'fix/correct-provider-type' into dev/plugin-deploy 2025-01-14 14:21:15 +08:00
Novice Lee 11428172eb fix: correct the provider type 2025-01-14 14:20:03 +08:00
Joel 0ae072dd75 chore: add plugin/deploy deploy 2025-01-14 14:13:43 +08:00
Joel d6b9648332 merge 2025-01-14 11:35:29 +08:00
JoelandGitHub 0a6b4d01d7 fix: save tool not add type (#12712) 2025-01-14 10:28:41 +08:00
Novice Lee 8865bdca05 feat: add agent strategy on node start 2025-01-13 13:30:35 +08:00
98b139c680 feat: add agent strategy on node start (#12667)
Co-authored-by: Novice Lee <novicelee@NoviPro.local>
2025-01-13 13:04:05 +08:00
zxhlyhandGitHub f0a3c14adb fix: plugins task (#12662) 2025-01-13 10:59:34 +08:00
YeuolyandGitHub 51947575c2 feat: add skip signature verification (#12627) 2025-01-10 20:37:33 +08:00
YeuolyandGitHub cb8debee3e Plugins/fix backend ci errors (#12615) 2025-01-10 19:46:59 +08:00
zxhlyhandGitHub d56079a549 fix: marketplace card i18n (#12623) 2025-01-10 18:15:58 +08:00
zxhlyhandGitHub c08b451874 fix: marketplace page list style (#12613) 2025-01-10 17:31:09 +08:00
非法操作andGitHub ac336ff359 fix(1.0): add missing environment variable (#12599) 2025-01-10 17:17:13 +08:00
JoelandGitHub 4cbd511cd7 fix: ci use pnpm error (#12597) 2025-01-10 16:55:16 +08:00
YeuolyandGitHub c03adcb154 Fix: style checks and unittests (#12603) 2025-01-10 16:40:39 +08:00
Hiroshi FujitaandGitHub 04dade2f9b fix: update fetchReleases to use owner and repo from meta (#12590) 2025-01-10 15:46:10 +08:00
kurokoboandGitHub f69220ca96 fix: add location directive for /explore (#12572) 2025-01-10 15:42:32 +08:00
Wu TianweiandGitHub a5e24ff6d3 fix: update language change handling in I18n component (#12596)
ok
2025-01-10 14:47:24 +08:00
zxhlyhandGitHub 71976f9192 fix: marketplace serach bundle (#12581) 2025-01-10 14:03:00 +08:00
39ec6c8025 Fix/setting model page crash (#12594)
Co-authored-by: JzoNg <jzongcode@gmail.com>
2025-01-10 13:10:58 +08:00
NFishandGitHub e370045ac4 Fix:screenshots image missed (#12589) 2025-01-10 11:47:20 +08:00
YeuolyandGitHub 28edbbac0b Plugins/bump to 1.0.0 beta.1 (#12568) 2025-01-09 22:46:24 +08:00
YeuolyandGitHub 782abcecd8 bump version to 1.0.0-beta.1 (#12567) 2025-01-09 22:38:20 +08:00
YeuolyandGitHub 4deb02fc2c fix: rename plugin db name to dify_plugin (#12565) 2025-01-09 21:56:24 +08:00
JoelandGitHub f967180dc2 fix: not show stragry type (#12561) 2025-01-09 20:55:17 +08:00
YeuolyandGitHub cead13cbc3 plugins: remove middleware.1.yaml (#12559) 2025-01-09 20:34:49 +08:00
YeuolyandGitHub 078c151065 fix: add-default-console-url (#12558) 2025-01-09 20:34:13 +08:00
YeuolyandGitHub 17babca362 Introducing: Plugin Mechanism (#12553) 2025-01-09 19:54:17 +08:00
AkaraChenandGitHub 8efed8858c feat: reset parameters when switch agent strategy (#12549) 2025-01-09 19:31:02 +08:00
YeuolyandGitHub 0d411a0b5a feat: refactor docker-compose (#12550) 2025-01-09 19:08:11 +08:00
13f0c01f93 feat: add ci checks to plugins/beta branch (#12542)
Co-authored-by: Novice Lee <novicelee@NoviPro.local>
2025-01-09 18:57:09 +08:00
3c014f3ae5 Feat/plugins (#12547)
Co-authored-by: AkaraChen <akarachen@outlook.com>
Co-authored-by: Yi <yxiaoisme@gmail.com>
Co-authored-by: Joel <iamjoel007@gmail.com>
Co-authored-by: JzoNg <jzongcode@gmail.com>
Co-authored-by: twwu <twwu@dify.ai>
Co-authored-by: kurokobo <kuro664@gmail.com>
Co-authored-by: Hiroshi Fujita <fujita-h@users.noreply.github.com>
2025-01-09 18:47:41 +08:00
zxhlyh da8e1ded55 Merge branch 'feat/plugins' into dev/plugin-deploy 2025-01-09 18:33:53 +08:00
zxhlyh d78c7fc9f2 fix: agent log 2025-01-09 18:31:17 +08:00
JzoNg dc6e02f3ec fix plugin card 2025-01-09 17:46:46 +08:00
AkaraChen 4042c1f6c4 fix: prevent show error when data is not ready 2025-01-09 17:41:27 +08:00
AkaraChen b450c6f976 fix: checklist show error when strategy provider list not fetched 2025-01-09 17:41:08 +08:00
AkaraChen 4e29694a46 feat: show error when not select required model 2025-01-09 17:37:43 +08:00
AkaraChen 43f60cec24 feat: show error when not select required model 2025-01-09 17:37:29 +08:00
Yeuoly e4c4490175 refactor 2025-01-09 17:27:05 +08:00
AkaraChen 4bbcc78c84 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-09 17:23:06 +08:00
AkaraChen 31e0aea181 fix: checklist show error when import dsl 2025-01-09 17:23:01 +08:00
Novice Lee 26ab0314a9 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2025-01-09 17:21:10 +08:00
Novice Lee 4b5586375f feat: add node id in agent log 2025-01-09 17:20:53 +08:00
Yi 6b0325d01d fix: revert prev commit bc it causes corner issues 2025-01-09 17:15:55 +08:00
Yeuoly 94a62f6b4e enhancement: remove unrequired deps 2025-01-09 17:06:38 +08:00
Novice Lee ffbbd47d13 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2025-01-09 16:55:58 +08:00
Novice Lee d76af08784 feat: add agent log icon 2025-01-09 16:55:17 +08:00
Yeuoly f748d6c7c4 fix: mypy issues 2025-01-09 16:53:30 +08:00
Novice Lee 2b20ba697c Merge branch 'fix/chore-fix' into dev/plugin-deploy 2025-01-09 16:50:35 +08:00
Novice Lee ff5d12a437 feat: add agent log icon 2025-01-09 16:50:05 +08:00
Yi 3bdaf2dcae chore: avoid unnecessary loading for the model selector in agent node 2025-01-09 16:48:02 +08:00
JzoNg dfe69a9c13 keep panel show after tool selecting 2025-01-09 16:39:54 +08:00
AkaraChen 6d55ecd7fd fix: modal label show when no model selected 2025-01-09 16:39:42 +08:00
AkaraChen 90b390346b Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-09 16:22:24 +08:00
AkaraChen 60b582d97a chore: remove log 2025-01-09 16:22:13 +08:00
JzoNg ad94bcc2b3 Merge branch 'feat/plugins' into dev/plugin-deploy 2025-01-09 16:19:03 +08:00
JzoNg f2f0265b3e fix style of required 2025-01-09 16:18:08 +08:00
zxhlyh e1db41a1b3 Merge branch 'feat/plugins' into dev/plugin-deploy 2025-01-09 16:14:28 +08:00
zxhlyh f7edff6c6b fix: agent log 2025-01-09 16:13:59 +08:00
AkaraChen 145ef794b6 fix: switch version not work 2025-01-09 16:08:20 +08:00
AkaraChen efb6a5dd3e Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-09 15:48:00 +08:00
AkaraChen 0fe4fd65e2 fix: down arrow not shown not agent strategy selector 2025-01-09 15:47:50 +08:00
Joel ab66f30e1d feat: add parallel test case 2025-01-09 15:31:44 +08:00
AkaraChen 566dc9b4a8 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-09 15:17:31 +08:00
AkaraChen 641395b3ec feat: agent strategy form support required mark 2025-01-09 15:17:27 +08:00
Joel db60150f30 chore: change use new log struct generator 2025-01-09 15:08:05 +08:00
AkaraChen b964c713bd chore: add tooltip props to agent strategy select 2025-01-09 14:56:46 +08:00
AkaraChen 7b4d49a79c Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-09 14:53:07 +08:00
AkaraChen 0ad08f523b chore: add tooltip props to agent strategy select 2025-01-09 14:52:59 +08:00
Yi f4ca5938ec Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-09 14:47:17 +08:00
Yi 38437efec0 fix: change "upgrade" to "install" for generality in plugin version switch 2025-01-09 14:47:08 +08:00
JzoNg 9604e54df5 Merge branch 'feat/plugins' into dev/plugin-deploy 2025-01-09 14:42:53 +08:00
JzoNg 52553a66ba fix style of agent strategy 2025-01-09 14:40:58 +08:00
AkaraChen a87c2d7e20 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-09 14:31:49 +08:00
AkaraChen 08cff0045d feat: form not installed indicator 2025-01-09 14:31:43 +08:00
JzoNg 195a507b40 dark mode of api 2025-01-09 14:14:08 +08:00
JzoNg d7ec013665 modals of app overview 2025-01-09 14:14:08 +08:00
Joel 371febf3cf chore: merge 2025-01-09 13:55:37 +08:00
Joel dc9675d2d8 fix: plugin tool width in agent app 2025-01-09 13:53:07 +08:00
Joel 06fe17c93e chore: enchance fold into anim 2025-01-09 13:45:30 +08:00
Yeuoly edf9409877 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2025-01-09 13:37:15 +08:00
Yeuoly 76e24d91c0 fix: migrations 2025-01-09 13:30:43 +08:00
AkaraChen 5ec4695e4a feat: tool icon check plugin status 2025-01-09 13:29:23 +08:00
AkaraChen bb60db7078 feat: tool selector get icon from marketplace 2025-01-09 13:00:43 +08:00
AkaraChen e3e8eafd32 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-09 11:53:30 +08:00
AkaraChen eff6a55960 fix: install button 2025-01-09 11:53:24 +08:00
Yi a7f0933e55 chore: add checks in the url fetch step of the installFromGitHub 2025-01-09 11:52:44 +08:00
JzoNg eaf1177cd4 dark mode of overview card view 2025-01-09 11:35:37 +08:00
JzoNg 297b5280f0 tracing modal & config 2025-01-09 11:35:37 +08:00
Joel 4aac48ed61 feat: github install add anim 2025-01-09 11:29:48 +08:00
Joel 192af8df9f feat: local and bundle support hide anim 2025-01-09 11:16:33 +08:00
Novice Lee 805e9638da fix: change the agent strategy category 2025-01-09 11:14:08 +08:00
Novice Lee 5ce4ddc0ed fix: change the agent strategy category 2025-01-09 11:13:00 +08:00
Joel 9822445c1e chore: all hide logic to hooks 2025-01-09 11:04:23 +08:00
Joel 018e32e355 fix: installed not clear countdown 2025-01-09 10:49:22 +08:00
zxhlyh 41b720502f merge main 2025-01-09 10:40:46 +08:00
zxhlyh cd30fd5a9a Merge branch 'feat/plugins' into dev/plugin-deploy 2025-01-09 10:36:18 +08:00
zxhlyh a157af724f fix: marketplace submit button 2025-01-09 10:35:47 +08:00
AkaraChen cc0d864599 fix: agent node tool list header width 2025-01-09 09:55:56 +08:00
Novice Lee 00ad751a57 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2025-01-09 08:48:00 +08:00
Novice Lee 491d641485 feat: add agent node log 2025-01-09 08:32:32 +08:00
Yeuoly 172c5f19cc fix: formatter 2025-01-08 21:11:58 +08:00
Yeuoly b7d168ac59 fix: mypy linter 2025-01-08 21:11:42 +08:00
Yeuoly fb309462ad Merge branch 'main' into fix/chore-fix 2025-01-08 20:36:22 +08:00
JzoNg f1794a3d1b Merge branch 'feat/plugins' into dev/plugin-deploy 2025-01-08 20:02:34 +08:00
JzoNg 4a6a1b9855 chore: fix request form data 2025-01-08 20:01:01 +08:00
Joel 7ccc268ced fix: stop anim 2025-01-08 19:34:41 +08:00
Joel 6483d20f56 feat: install countdown 2025-01-08 19:25:01 +08:00
AkaraChen 5c82aebf4e Merge branch 'feat/plugins' into dev/plugin-deploy 2025-01-08 19:09:22 +08:00
Yi 61237e8037 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-08 17:55:41 +08:00
Yi aae601f233 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-08 17:55:19 +08:00
AkaraChen 701520ffd0 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-08 17:54:31 +08:00
AkaraChen 596e3409b7 fix: agent prompt 2025-01-08 17:54:24 +08:00
Yi 38dd285656 fix: long model name display issue 2025-01-08 17:53:25 +08:00
zxhlyh 9ab39c3feb Merge branch 'feat/plugins' into dev/plugin-deploy 2025-01-08 17:49:11 +08:00
zxhlyh 0248c8cb8c fix: agent key 2025-01-08 17:48:26 +08:00
AkaraChen 88b3c0b7a6 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-08 17:36:32 +08:00
AkaraChen 3ae7787011 fix: number not supported 2025-01-08 17:36:26 +08:00
Yi c357ec0f7c chore: add loading to the model selector trigger 2025-01-08 17:27:03 +08:00
Yi 763f91fcea Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-08 17:12:01 +08:00
Yi 62d53399ae fix: add bg color to the top section in plugins page 2025-01-08 17:11:55 +08:00
Joel c3215a8f94 feat: fold into animation 2025-01-08 17:02:47 +08:00
AkaraChen d65c1218ae Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-08 16:57:01 +08:00
AkaraChen 83723212af fix: agent node getNodeUsedVars 2025-01-08 16:56:56 +08:00
Yi 84c2a9dc3b Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-08 16:51:14 +08:00
Yi 87d7df3ed4 fix: make the status indicator component compatible with the switch plugin version component 2025-01-08 16:51:06 +08:00
zxhlyh 5cc9c79284 Merge branch 'feat/plugins' into dev/plugin-deploy 2025-01-08 16:47:27 +08:00
zxhlyh 586f9d8d89 fix: agent log 2025-01-08 16:46:35 +08:00
WTW0313 b656b7a0dd Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-08 16:41:22 +08:00
WTW0313 0fdf7b23c6 feat: add 'agent' tag to plugin constants and translations 2025-01-08 16:41:16 +08:00
Yi 369e3eb97f feat: add version switch in model selector 2025-01-08 16:39:56 +08:00
AkaraChen f58eef74b3 feat: switch plugin version changelog 2025-01-08 16:19:41 +08:00
AkaraChen 2fd083629d feat: new switch plugin version 2025-01-08 15:58:05 +08:00
Yi 755685a89a Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-08 15:54:21 +08:00
Yi 23b29b1d21 fix: check-dependencies typo and fetch model list typo 2025-01-08 15:54:04 +08:00
zxhlyh 4b01ef2b48 fix: chat log 2025-01-08 15:42:18 +08:00
JzoNg 05d273d643 fix tracing dropdown 2025-01-08 15:40:13 +08:00
JzoNg 5481b42257 dark mode for tracing dropdown 2025-01-08 15:28:45 +08:00
AkaraChen fa83f2e2fa fix: switch version plugin 2025-01-08 15:13:19 +08:00
AkaraChen 5e4d2f9501 Revert "chore: remove switch version component in strategy select"
This reverts commit f63cc9e069.
2025-01-08 14:55:55 +08:00
Yi fdfe724438 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-08 14:50:25 +08:00
Yi b0b373d2fb fix: revert the modelInList check in the model icon component 2025-01-08 14:50:14 +08:00
AkaraChen f63cc9e069 chore: remove switch version component in strategy select 2025-01-08 14:48:36 +08:00
Yi 8c9c336b64 fix: isInModelList default value 2025-01-08 14:47:01 +08:00
Yi 2dac103463 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-08 14:45:10 +08:00
Yi 17dfb3654f feat: add version incompatible case 2025-01-08 14:45:03 +08:00
zxhlyh 730d33176e Merge branch 'feat/plugins' into dev/plugin-deploy 2025-01-08 14:20:36 +08:00
zxhlyh 98ad18ba81 fix: agent log 2025-01-08 14:20:08 +08:00
AkaraChen 53bb1bb937 fix: agent node cannot output var 2025-01-08 14:09:35 +08:00
AkaraChen 93806148cd chore: plugin mutation modal component 2025-01-08 12:37:33 +08:00
JzoNg adf0d94a9a unsupported actions 2025-01-08 11:51:59 +08:00
zxhlyh d17932d723 fix: install task icon 2025-01-08 10:12:55 +08:00
Yi 3cbb288a25 feat: add version check i18n 2025-01-08 10:09:11 +08:00
AkaraChen 99e2eaa6ee fix: switch plugin version 2025-01-08 10:03:00 +08:00
Novice Lee 86318d9137 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2025-01-08 08:04:48 +08:00
Novice Lee b56d2b739b feat: add fc agent mode support 2025-01-08 07:41:17 +08:00
Yeuoly c706226b2f Merge branch 'fix/chore-fix' into dev/plugin-deploy 2025-01-07 20:53:25 +08:00
Yeuoly fb7b2c8ff3 fix: backwards invoke nodes 2025-01-07 20:52:25 +08:00
Yeuoly f9f48b7139 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2025-01-07 20:16:04 +08:00
Yeuoly c3440a27fb fix 2025-01-07 18:59:13 +08:00
Joel 6006380723 fix: tool select ui problem in workflow 2025-01-07 17:10:27 +08:00
Joel 55ad1fe1f0 chore: tool selelct use the same tools data 2025-01-07 16:58:31 +08:00
Yi 0383fce821 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-07 16:57:09 +08:00
Yi 85610651c0 node ui fix 2025-01-07 16:57:01 +08:00
AkaraChen 768e1b9da3 fix: wrong tooltip content for switch plugin version 2025-01-07 16:43:36 +08:00
Joel a6d172f111 feat: github refresh plugin list 2025-01-07 16:42:40 +08:00
Joel 5817c07db6 feat: local install refresh 2025-01-07 16:34:08 +08:00
Yi 2f5da1f6aa fix: update model icon 2025-01-07 16:31:15 +08:00
JzoNg d7657f4874 Merge branch 'feat/plugins' into dev/plugin-deploy 2025-01-07 15:57:17 +08:00
AkaraChen 130cfaf2a4 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-07 15:20:00 +08:00
AkaraChen f840b7db0c fix: type for tool list 2025-01-07 15:19:46 +08:00
JzoNg aac2184069 chore: use install button in tool item 2025-01-07 15:18:07 +08:00
AkaraChen f03631ff9e feat: init agent strategy install from marketplace 2025-01-07 15:08:36 +08:00
Yeuoly ff3d3f71fb fix: use host.docker.internal as the default plugin daemon middleware endpoint 2025-01-07 14:56:03 +08:00
Yeuoly 485d510e80 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2025-01-07 14:50:29 +08:00
Yi e207894d7e Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-07 14:45:00 +08:00
Yeuoly 9685b9a302 refactor: docker-compose-middleware.yaml 2025-01-07 14:44:08 +08:00
Yi 8512a7d3ad chore: update the onOpenModel function to a hook 2025-01-07 14:43:54 +08:00
JzoNg 46614cc6f5 fix badge & refresh state of tool install state 2025-01-07 14:41:48 +08:00
AkaraChen b39acd0bad Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-07 14:03:53 +08:00
AkaraChen 48b88b90f5 feat: i18n text in agent strategy selector 2025-01-07 14:03:40 +08:00
zxhlyh 851fe246a7 fix: installing info in plugin nav 2025-01-07 14:00:29 +08:00
Yi ff61c22f36 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-07 12:48:42 +08:00
Yi e6eae8568f chore: update the model install button 2025-01-07 12:48:36 +08:00
JzoNg 6d5c34564b fix qrcode z-index 2025-01-07 12:16:34 +08:00
JzoNg 6d8b54f1e5 Merge branch 'feat/plugins' into dev/plugin-deploy 2025-01-07 11:58:29 +08:00
AkaraChen 4c5fa00c50 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-07 11:57:40 +08:00
AkaraChen 910e6d17d3 feat: adjust strategy selector height 2025-01-07 11:57:35 +08:00
JzoNg 275696edba fix system model selector 2025-01-07 11:53:34 +08:00
JzoNg 1348e32015 fix balance model z-index 2025-01-07 11:53:34 +08:00
JzoNg f5b2735dd5 theme default light 2025-01-07 11:53:34 +08:00
JzoNg 8d39ec1da5 chart drak mode 2025-01-07 11:53:34 +08:00
Yi 0f6cbf25d3 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-07 11:34:09 +08:00
Joel 0e98794d49 feat: use all refresh plugin tools to hooks 2025-01-07 11:31:22 +08:00
AkaraChen 1419430015 chore: upd 2025-01-07 11:25:06 +08:00
Yi 5d25643f54 fix: group icon style 2025-01-07 11:18:01 +08:00
AkaraChen e24b04b30f refactor: switch plugin version component to not accept version 2025-01-07 10:58:53 +08:00
AkaraChen a8c4870349 refactor: switch plugin version component to not accept version 2025-01-07 10:55:42 +08:00
AkaraChen bdb9d676b1 chore: update switch plugin i18n 2025-01-07 10:49:26 +08:00
AkaraChen 0beebab605 fix: workflow store agent strategy not up to date 2025-01-07 09:57:35 +08:00
AkaraChen 15f3e46c49 refactor: some field name in strategy status 2025-01-07 09:30:35 +08:00
Yeuoly 07c7b7b886 fix: remove 5002 port from docker mapping 2025-01-06 21:45:44 +08:00
kurokoboandGitHub 8d75abc976 fix: correct fetch_from for customizable models (#12400) 2025-01-06 21:16:39 +08:00
Yeuoly aa6452b3bf fix: use session to manage AppSite 2025-01-06 21:12:50 +08:00
Yeuoly 3799d40937 feat: support docker deployment for plugin 2025-01-06 20:28:50 +08:00
Joel 61d2f70927 feat: add transform node to node data 2025-01-06 18:36:45 +08:00
Joel 228cd1cdbe feat: add iteration id 2025-01-06 16:48:24 +08:00
Joel e0ed17a2e6 chore: can generator middle struct 2025-01-06 15:31:25 +08:00
Yeuoly d2ff8a2381 fix: bugs 2025-01-06 14:59:40 +08:00
zxhlyh 07aa2ca9cf fix: single run log 2025-01-03 16:34:23 +08:00
Joel 5fdfba6b00 feat: make iteration 2025-01-03 15:41:04 +08:00
AkaraChen fbf9984d85 refactor: strategy status 2025-01-03 15:25:10 +08:00
Yeuoly 150b4ea1eb Merge branch 'fix/chore-fix' into dev/plugin-deploy 2025-01-03 14:48:39 +08:00
Yeuoly 5f51a19de2 fix: allow meta to be None 2025-01-03 14:48:19 +08:00
Yeuoly beeb11a5dc Merge branch 'fix/chore-fix' into dev/plugin-deploy 2025-01-03 14:10:22 +08:00
Yeuoly 71e0bfcbd8 fix: updating tool credentials does not works as expected 2025-01-03 14:09:17 +08:00
AkaraChen 2296bb162b Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-03 13:52:43 +08:00
AkaraChen 06f0c3c886 refactor: strategy status 2025-01-03 13:52:38 +08:00
JzoNg 483890b207 fix install in tool item 2025-01-03 13:39:23 +08:00
AkaraChen 390107f97e Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-03 10:35:11 +08:00
AkaraChen 5ba0b85738 feat: install plugin button 2025-01-03 10:35:06 +08:00
JzoNg 39335b8038 refactor I18n render in plugin detail 2025-01-03 10:16:44 +08:00
twwu 5fb356fd33 refactor: rename renderI18nObject to getValueFromI18nObject for clarity 2025-01-02 18:07:44 +08:00
twwu c458c28c62 feat: enhance plugin item localization with i18n support 2025-01-02 17:35:11 +08:00
AkaraChen 055fb22b9b Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-02 16:36:03 +08:00
AkaraChen f2eb095960 feat: strategy install status 2025-01-02 16:35:58 +08:00
Joel d5cfb26db6 feat: support make retry data 2025-01-02 16:29:12 +08:00
zxhlyh 7519c9a0d6 Merge branch 'feat/plugins' into dev/plugin-deploy 2025-01-02 15:51:21 +08:00
zxhlyh a514bde428 fix: marketplace page size 2025-01-02 15:50:40 +08:00
AkaraChen 87ce813175 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-02 15:03:23 +08:00
AkaraChen 336b26569b feat: agent form string type support var 2025-01-02 15:03:18 +08:00
zxhlyh a432fcfd5e agent node single run 2025-01-02 14:56:15 +08:00
AkaraChen 0ed4ec5cd0 fix: agent strategy selector show workflow 2025-01-02 14:48:40 +08:00
AkaraChen add6dff789 feat: agent node check install strategy 2025-01-02 14:27:19 +08:00
Joel c469da2020 fix: handle install title and descript may caused i18n problem 2025-01-02 14:22:04 +08:00
Joel 55aad3718d fix: multi loop nodes remove children error 2025-01-02 14:09:57 +08:00
AkaraChen c6c388fbda feat: agent checklist i18n 2025-01-02 13:58:30 +08:00
AkaraChen d3d606799d Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2025-01-02 11:46:52 +08:00
AkaraChen c1ae681b6c feat: agent checklist i18n 2025-01-02 11:46:47 +08:00
Joel f11ea5ae97 fix: title not show all if space is enough 2025-01-02 11:37:31 +08:00
Joel e112357e91 chore: temp 2025-01-02 11:37:31 +08:00
AkaraChen 1b8ec6710a feat: agent node checklist 2025-01-02 11:29:10 +08:00
Joel d49974665e Merge branch 'feat/plugins' into dev/plugin-deploy 2025-01-02 11:02:24 +08:00
Joel a8881cc7a6 chore: temp 2025-01-02 11:00:03 +08:00
JzoNg 6f97eb5713 merge feat/plugins 2025-01-02 08:51:03 +08:00
JzoNg 4663af8a60 tool setting schema 2025-01-02 08:43:09 +08:00
Yeuoly 65077cd388 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-31 17:43:16 +08:00
Yeuoly d815c74fc5 fix: ruff 2024-12-31 16:48:20 +08:00
Yeuoly 107e44c8fb Merge branch 'main' into fix/chore-fix 2024-12-31 16:47:56 +08:00
Yeuoly adf7eea7fe fix: ruff 2024-12-31 16:40:26 +08:00
Yeuoly 6e73ad2fc6 feat: plugin migrations 2024-12-31 16:38:02 +08:00
AkaraChen 91ac660f81 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-31 16:33:22 +08:00
AkaraChen 3c829a1c28 fix: some style 2024-12-31 16:33:16 +08:00
Yi f9ce6b6a6e Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-31 16:13:13 +08:00
Yi afe8c85b99 model feature icons 2024-12-31 16:13:06 +08:00
zxhlyh bc5cd4405b agent node single run 2024-12-31 16:08:09 +08:00
Yi be36aedac1 agent node: fix installed model ui 2024-12-31 15:59:43 +08:00
AkaraChen 9e6f3e9161 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-31 15:53:45 +08:00
AkaraChen 52537c9e6b fix: model deprecated in model list 2024-12-31 15:53:38 +08:00
Joel 8d229f26d0 fix: card name too long 2024-12-31 15:47:48 +08:00
Yi 504c794e8a add icons and fix ui typos 2024-12-31 15:47:14 +08:00
Joel cab8c6c5a7 feat: support scroll into letter 2024-12-31 15:41:29 +08:00
Yi 5bba422c0b fix model icon size in llm node 2024-12-31 15:13:56 +08:00
AkaraChen 870779534f Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-31 15:04:17 +08:00
AkaraChen f956c2edcd chore: update style 2024-12-31 15:04:13 +08:00
Joel 2a29dd3534 fix: letter list not right 2024-12-31 15:01:31 +08:00
Yi b1831bc582 fix the model icon ui 2024-12-31 14:35:11 +08:00
Yi 3e979a5ded fix: model selector's trigger ui 2024-12-31 14:23:13 +08:00
zxhlyh 7011a5029e merge main 2024-12-31 14:12:35 +08:00
zxhlyh a66d92054a Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-31 14:09:11 +08:00
zxhlyh d7cbbbca8e fix: tool single run 2024-12-31 14:08:40 +08:00
zxhlyh 21d082f3da feat: tool single run 2024-12-31 14:05:56 +08:00
Yi 2cdf2b2e05 fix the model icon size in the agent node 2024-12-31 14:04:03 +08:00
Yi ec2dd750f1 fix: set a fixed height to the model selection in agent node 2024-12-31 13:59:55 +08:00
AkaraChen 066595f3aa chore: remove unused code 2024-12-31 13:50:31 +08:00
AkaraChen f81bbee6b6 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-31 13:46:12 +08:00
AkaraChen 4855e87876 fix: editor 2024-12-31 13:46:06 +08:00
JzoNg e47aaad396 remove test codes 2024-12-31 12:42:49 +08:00
JzoNg df421796bb add model info in model selector 2024-12-31 12:41:08 +08:00
AkaraChen fe5702784e Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-31 11:52:20 +08:00
AkaraChen eba4042a62 wip: instruction field 2024-12-31 11:52:15 +08:00
Joel 3bed0346d7 fix: choose tools 2024-12-31 11:51:50 +08:00
Yi 3a09f43f70 feat: update the install logic 2024-12-31 11:46:36 +08:00
Yi 232fb66edd ui fixes in model selector 2024-12-31 11:08:53 +08:00
Yeuoly f5dc873b81 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-30 21:14:47 +08:00
Yeuoly 06412b37d3 fix: no attribbute identity 2024-12-30 21:14:24 +08:00
Joel a3f736f6e5 feat: multi steps circle 2024-12-30 18:39:33 +08:00
Joel d9d42b2d8c feat: multi step circle 2024-12-30 18:38:07 +08:00
Joel 0a30018330 chore: one step circle check 2024-12-30 18:27:59 +08:00
Joel 128410902c temp 2024-12-30 18:27:59 +08:00
Yi 9b6f580365 add model install in model configuration for the agent node 2024-12-30 17:55:46 +08:00
AkaraChen afb3548e45 refactor: agent parameters 2024-12-30 17:40:56 +08:00
JzoNg e1cb85cee1 fix label of tool picker 2024-12-30 15:43:24 +08:00
JzoNg f6c1ae52dd Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-30 15:30:29 +08:00
JzoNg 2007828404 installation state of tool 2024-12-30 15:28:15 +08:00
AkaraChen f5b4366bd8 fix: agent node 2024-12-30 14:49:12 +08:00
Yeuoly db1ad3c0f1 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-30 13:42:10 +08:00
Yeuoly 63665a5ff1 feat: add conversation_id to invoke 2024-12-30 13:41:54 +08:00
Yeuoly 7330a4a783 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-30 13:35:10 +08:00
Yeuoly 05a43e3e80 fix: rebaseing to main 2024-12-30 13:34:45 +08:00
AkaraChen cd7e6ca010 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-30 13:31:02 +08:00
AkaraChen 2ac6f00efb fix: agent node toolbox 2024-12-30 13:30:57 +08:00
Yi f461f56886 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-30 12:55:42 +08:00
Yi ba16cbccf0 feat: add install options for model configuration 2024-12-30 12:55:28 +08:00
AkaraChen 08a1f241ca Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-30 11:28:57 +08:00
AkaraChen a5509fbe5a feat: agent node toolbox 2024-12-30 11:28:51 +08:00
zxhlyh 76d7a64c37 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-30 11:25:59 +08:00
zxhlyh 98a03b0593 fix: agent log structure 2024-12-30 11:25:28 +08:00
zxhlyh f72818bed5 fix: agent log structure 2024-12-30 11:14:59 +08:00
JzoNg 0c5101fb3c fix default value for multiple tool selector 2024-12-30 10:38:45 +08:00
zxhlyh 84febd5e94 fix: agent log structure 2024-12-30 10:23:48 +08:00
JzoNg b5ad9a58f7 default value for multiple tool selector 2024-12-30 10:23:00 +08:00
Yeuoly 7122bf3e8e Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-27 22:56:55 +08:00
Yeuoly 83fdb42520 fix: variable message 2024-12-27 22:56:39 +08:00
Yeuoly 4fb5cf675b Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-27 18:37:54 +08:00
Yeuoly cbf405beea fix: remigrate 2024-12-27 18:37:34 +08:00
Joel 8a90a9bd5d fix: in steam mode trigger the error in change list 2024-12-27 18:28:52 +08:00
zxhlyh bc78803171 merge feat/plugins 2024-12-27 18:11:52 +08:00
zxhlyh 6f8e217580 refact workflow run log 2024-12-27 18:10:44 +08:00
Yeuoly af2aede783 feat: support precision to PluginParameter 2024-12-27 18:07:28 +08:00
Yeuoly b1522e860a Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-27 17:55:57 +08:00
Yeuoly e359ace633 fix: add agent logs 2024-12-27 17:55:41 +08:00
Yeuoly d4a7d05043 fix: linter 2024-12-27 17:39:12 +08:00
Yeuoly 4ee4740657 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-27 17:38:10 +08:00
JzoNg 891a76f2fa enabled count 2024-12-27 17:37:18 +08:00
Yeuoly a5555f90c6 fix: models 2024-12-27 17:34:17 +08:00
Yeuoly 78664c8903 Merge branch 'main' into fix/chore-fix 2024-12-27 17:33:58 +08:00
JzoNg 3c85363392 multiple tool selector 2024-12-27 17:29:46 +08:00
zxhlyh a863e9f674 refact workflow run log 2024-12-27 17:22:11 +08:00
Joel 6a2a7aca9b chore: tool node support agent logs 2024-12-27 16:52:22 +08:00
AkaraChen 18393d2e27 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-27 16:48:32 +08:00
AkaraChen de48a1c7e9 fix: type error 2024-12-27 16:48:16 +08:00
Joel 3d5620dfb3 fix: parallel start node not insert into the right place 2024-12-27 16:47:05 +08:00
AkaraChen da2982ba98 feat: model list on agent node 2024-12-27 16:45:46 +08:00
AkaraChen 0108b28305 feat: model list on agent node 2024-12-27 16:39:18 +08:00
JzoNg 573c8f909c add multiple tool selector 2024-12-27 16:30:34 +08:00
Joel 3a5170716b fix: pararllel title 2024-12-27 16:29:15 +08:00
zxhlyh 0631cf0c4f Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-27 16:18:41 +08:00
zxhlyh e4cc8f7010 refact workflow run log 2024-12-27 16:18:04 +08:00
AkaraChen 23913b8640 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-27 16:04:53 +08:00
AkaraChen 0d0a4cfaa1 fix: select var 2024-12-27 16:04:48 +08:00
Joel 04d8d16d8a chore: fix retry not work in iteration 2024-12-27 15:54:56 +08:00
AkaraChen 0d2a74b8cb feat: output var 2024-12-27 15:34:54 +08:00
Yeuoly 45070535bd fix: linter 2024-12-27 14:47:48 +08:00
JzoNg 1b93e1ff99 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-27 14:47:22 +08:00
JzoNg ae42edb8d7 remove test code 2024-12-27 14:43:07 +08:00
AkaraChen e903cd8073 fix: llm node 2024-12-27 14:31:50 +08:00
Joel a071d2cd1b Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-27 14:25:12 +08:00
Joel 31cca291b7 chore: remove test page 2024-12-27 14:22:00 +08:00
zxhlyh 1cc15d1ce8 merge feat/plugins 2024-12-27 14:21:32 +08:00
JzoNg ed6c9625e8 fix scope features 2024-12-27 14:20:46 +08:00
Joel 08c517dd99 feat: iteration support parallel 2024-12-27 14:20:18 +08:00
JzoNg 69a6556f52 tool item 2024-12-27 14:09:52 +08:00
Yi e34eebfb0b Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-27 13:58:05 +08:00
Yi ef3e904839 feat: model-selector in Agent node (case: installed models) 2024-12-27 13:57:54 +08:00
AkaraChen df5fb6dca9 feat: agent strategy max iter slider 2024-12-27 13:30:39 +08:00
Joel 2f65d0439c fix: not parall not group by branch 2024-12-27 13:08:05 +08:00
Yeuoly e7a6bc0ec9 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-27 12:17:08 +08:00
Yeuoly 048e8cf0d1 fix: remove validate credentials 2024-12-27 12:16:58 +08:00
Yeuoly 598d208e54 fix: agent error handling 2024-12-27 12:09:39 +08:00
zxhlyh 5cdca9cafe fix: marketplace i18n 2024-12-27 11:54:42 +08:00
Yi 67019d128b Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-27 11:49:03 +08:00
AkaraChen 697ee496b7 chore: upd mock form for dev 2024-12-27 11:43:29 +08:00
Yeuoly 494cca82a0 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-27 11:33:13 +08:00
Yeuoly 8102cee8df fix: unbound reference 2024-12-27 11:33:04 +08:00
AkaraChen 7f5e27d001 chore: extend form component for override 2024-12-27 11:30:43 +08:00
Joel 1f128729f4 fix: sub iteration would crash page 2024-12-27 11:24:47 +08:00
Yi a562e6db89 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-27 10:47:07 +08:00
Joel c23fe3b67f chore: format 2024-12-27 10:25:15 +08:00
Yeuoly 2b8f31ec98 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-26 22:58:48 +08:00
Yeuoly c9eb9c14d7 fix: block call to flask_app 2024-12-26 22:58:34 +08:00
Yeuoly 673ba9330c Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-26 22:30:38 +08:00
Yeuoly e77cd87842 fix: linter 2024-12-26 22:30:22 +08:00
Yeuoly ac5e3caebc optimize: migrate speed 2024-12-26 22:30:06 +08:00
JzoNg 95da3a4cf1 tool credential panel 2024-12-26 18:58:01 +08:00
Yeuoly b7f04c1ba8 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-26 18:07:39 +08:00
Yeuoly 23066a9ba8 feat: support extracting plugins into local files 2024-12-26 18:05:14 +08:00
JzoNg bfecc73de9 support extra for tool selector 2024-12-26 17:58:34 +08:00
Yi b4e9dddbca Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-26 17:40:42 +08:00
Yeuoly c95c3655fa Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-26 17:39:32 +08:00
Yeuoly 0249f15609 fix: linter 2024-12-26 17:39:21 +08:00
Yeuoly 2f523dd29f optimize: add friendly logs 2024-12-26 17:39:13 +08:00
JzoNg 10218cfe8d add tool selector in agent node 2024-12-26 17:33:06 +08:00
Yeuoly bc1502b8fc Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-26 17:26:19 +08:00
Yeuoly b34d815883 feat: support auto generate and template 2024-12-26 17:25:56 +08:00
JzoNg e00da7a1d8 tool setting form 2024-12-26 17:06:15 +08:00
JzoNg 469ce0f23d add tool description 2024-12-26 17:06:15 +08:00
JzoNg 23bf0a6812 tool selector support scope 2024-12-26 17:06:11 +08:00
AkaraChen 605085bddf chore: remove max_iterations for agent node 2024-12-26 16:42:34 +08:00
Yi dbc45f0d74 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-26 16:36:09 +08:00
zxhlyh 6175f8c16f merge main 2024-12-26 16:35:11 +08:00
zxhlyh 7e94056507 refact workflow run log 2024-12-26 15:44:59 +08:00
AkaraChen 1429b30e84 chore: upd 2024-12-26 15:27:15 +08:00
AkaraChen 5ef9156242 feat: custom credential form 2024-12-26 14:44:05 +08:00
zxhlyh 6f865b96a2 refact workflow run log 2024-12-26 14:41:00 +08:00
AkaraChen b7e56a23a0 feat: custom credential form 2024-12-26 14:32:21 +08:00
Yeuoly e7d3add5df Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-26 14:12:58 +08:00
Yeuoly 51cc63d9ce fix: undefined dereference to ApiTool 2024-12-26 14:12:43 +08:00
Yeuoly 430af95b53 fix: linter 2024-12-26 14:07:29 +08:00
Yeuoly 0164d1410a migrations for plugins 2024-12-26 14:07:12 +08:00
Yeuoly f0178bd603 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-26 13:24:16 +08:00
Yeuoly cbc5045b7a fix: ruff formatter 2024-12-26 13:23:56 +08:00
Yeuoly b980c07af8 fix: ruff formatter 2024-12-26 13:22:18 +08:00
Yeuoly e231cf2c48 fix: errors occrus during rebasing 2024-12-26 13:20:12 +08:00
Yi 5b8ad3ac4b Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-26 13:19:32 +08:00
AkaraChen e0b7f48b6b chore: add i18n str 2024-12-26 13:02:00 +08:00
Yi ff70e14de2 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-26 12:44:41 +08:00
AkaraChen 244517e6e7 fix: no icon in tool select 2024-12-26 12:41:44 +08:00
AkaraChen cd08f98bff chore: upd app icon 2024-12-26 12:32:02 +08:00
Yi b752c0654e Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-26 10:59:33 +08:00
AkaraChen e07d7ee4fc chore: remove console 2024-12-26 10:55:30 +08:00
Yi c476f06388 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-26 10:53:02 +08:00
AkaraChen 5f13402c6e Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-26 10:17:21 +08:00
AkaraChen 8dcd82290c feat: select strategy 2024-12-26 10:16:52 +08:00
zxhlyh 86eb618b84 refact workflow run log 2024-12-26 10:16:12 +08:00
Joel e1ea82475d feat: format agent 2024-12-25 18:37:05 +08:00
Yeuoly cd00602213 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-25 18:25:21 +08:00
Yeuoly 80d8e47e42 fix: skip json transforming if error occurs 2024-12-25 18:23:31 +08:00
zxhlyh 08515957f1 refact workflow run log 2024-12-25 16:57:22 +08:00
Joel 8503099d65 feat: integration 2024-12-25 16:46:32 +08:00
Yi c04a89d5b1 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-25 16:39:22 +08:00
Joel 8d225264fa feat: retry 2024-12-25 16:25:19 +08:00
zxhlyh 26901b2c87 refact workflow run log 2024-12-25 16:15:20 +08:00
JzoNg b56acb825f fix org info in tool detail panel 2024-12-25 15:34:07 +08:00
Yeuoly fee4dd7d7a fix: unused stream variable 2024-12-25 15:32:59 +08:00
Yi f1e17ad134 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-25 15:24:59 +08:00
AkaraChen b8e4580074 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-25 15:23:50 +08:00
Yeuoly 00cf5f3841 fix: linters 2024-12-25 15:18:29 +08:00
JzoNg 935c126abd strategy detail panel 2024-12-25 15:15:55 +08:00
JzoNg b4105fcc9c strategy list 2024-12-25 15:15:55 +08:00
AkaraChen 5f65fb1b62 chore: add model select mock 2024-12-25 15:12:33 +08:00
Yeuoly 02abf950e1 Merge fix/chore-fix into dev/plugin-deploy 2024-12-25 15:12:05 +08:00
Yi 986d6eed36 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-25 15:10:05 +08:00
AkaraChen e0f83d06d8 chore: add model select mock 2024-12-25 15:06:58 +08:00
Yi f42cfe8075 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-25 14:54:22 +08:00
AkaraChen a7b2f9aef0 chore: add i18n 2024-12-25 14:52:11 +08:00
Yeuoly 9ee0c7a694 merge 2024-12-25 14:39:15 +08:00
AkaraChen c867584049 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-25 14:24:02 +08:00
AkaraChen ac2c8344f2 chore: add i18n 2024-12-25 14:23:57 +08:00
Joel 8c662e04e0 feat: add iteration error 2024-12-25 14:20:39 +08:00
AkaraChen e1d0c29711 chore: add icon for agent 2024-12-25 14:13:20 +08:00
Yi 50c77ad405 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-25 14:12:54 +08:00
Joel 880496db0b chore: add more tests 2024-12-25 14:12:53 +08:00
AkaraChen 057da6c31b chore: gen agent icon 2024-12-25 14:07:05 +08:00
AkaraChen c0a8b89e93 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-25 14:06:08 +08:00
AkaraChen a8a956b5f1 chore: add i18n 2024-12-25 14:05:49 +08:00
Joel ff02e1cb8f chore: enchance test output struct 2024-12-25 14:04:46 +08:00
Yi d78719a6f8 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-25 13:41:06 +08:00
JzoNg da6d65b072 fix style of account setting 2024-12-25 12:35:27 +08:00
JzoNg 8d1a8eac51 add use-strategy 2024-12-25 11:55:59 +08:00
Joel e34fe3d10a feat: support iteration handle 2024-12-25 11:47:31 +08:00
Yi 8d79b24883 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-12-25 11:43:00 +08:00
AkaraChen 03520a5a81 feat: strategy form init 2024-12-25 11:24:24 +08:00
Yeuoly 6ee7ca1890 fix: add specific exceptions 2024-12-24 22:00:45 +08:00
Yeuoly f589397f25 fix: import Optional 2024-12-24 21:56:55 +08:00
Yeuoly ee080dddf9 fix: rebase 2024-12-24 21:48:49 +08:00
Yeuoly ee6841648c fix: migrations and imports recycle 2024-12-24 21:36:42 +08:00
Yeuoly 5a57dad93c fix: linter 2024-12-24 21:29:24 +08:00
Yeuoly 4199998c7e Merge branch 'main' into fix/chore-fix 2024-12-24 21:28:56 +08:00
Yeuoly 527abcb2e9 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-24 18:39:42 +08:00
Yeuoly 39656f7f84 fix: linter and formatter 2024-12-24 18:38:34 +08:00
Yeuoly bf39e314d8 fix: add install count 2024-12-24 18:38:12 +08:00
Yi d43b2c62f5 Merge branch 'main' into feat/plugins 2024-12-24 17:44:12 +08:00
JzoNg 07d7965e3b support custom output schema in tool node 2024-12-24 16:26:09 +08:00
Joel e4d72f3442 chore: hide log 2024-12-24 16:10:37 +08:00
Joel c93c264c5a feat: format to tracing 2024-12-24 16:08:48 +08:00
AkaraChen 77017522b8 chore: init tool select component 2024-12-24 16:01:14 +08:00
AkaraChen aa309964e5 chore: init tool select component 2024-12-24 15:55:45 +08:00
zxhlyh 754baf8d02 refact workflow run 2024-12-24 15:38:54 +08:00
zxhlyh b98dd22491 refact workflow run 2024-12-24 15:31:46 +08:00
AkaraChen 7c460eb6e7 chore: add warning ui for agentic stragey 2024-12-24 14:20:15 +08:00
JzoNg e2e2090e0c support model params change 2024-12-24 14:15:18 +08:00
JzoNg c8fc1deca6 support & operator of model-selector scope 2024-12-24 12:18:03 +08:00
Yi 6dd14ca2be chore: add agent strategy option apart from bundle 2024-12-24 12:05:35 +08:00
zxhlyh ec6f4ee9df Merge branch 'main' into feat/plugins 2024-12-24 11:35:47 +08:00
JzoNg 9d117fa2f9 param rules panel 2024-12-24 11:00:31 +08:00
Joel e8319f01e0 fix: crash 2024-12-24 10:33:56 +08:00
Joel c3f3b79b79 merge main 2024-12-23 15:33:08 +08:00
JzoNg c91c5faa9d Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-20 16:44:23 +08:00
JzoNg 327eac09e7 fix: scope value 2024-12-20 16:37:30 +08:00
JzoNg cf75e2f053 model selector support scope 2024-12-20 16:36:22 +08:00
JzoNg 12c47d80af support llm tool_parameters 2024-12-20 12:46:07 +08:00
JzoNg 5c6916354e app selector support scope 2024-12-20 11:59:18 +08:00
JzoNg 6d2b2d7810 fix number of tool actions 2024-12-20 11:27:52 +08:00
JzoNg 1fa5b1755f dark mode for model provider 2024-12-20 10:44:39 +08:00
twwu 5dad4793e6 fix: Fix context selector usage in plugin page components 2024-12-20 09:56:06 +08:00
Yeuoly 82f6803e25 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-19 01:09:34 +08:00
Yeuoly 8cc4c109d0 fix: return types of builtin tools 2024-12-19 01:09:15 +08:00
Yeuoly 69b43c513a Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-19 01:02:56 +08:00
Yeuoly a1cdca02e3 fix: formatter 2024-12-19 01:02:44 +08:00
Yeuoly 1b21d7513d fix: reduce model provider fetchs 2024-12-19 01:02:08 +08:00
Yeuoly f407cf4e13 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-19 00:52:02 +08:00
takatost d5c708c62b feat: add plugin_model_providers context 2024-12-19 00:50:46 +08:00
Yeuoly f8bbea224f Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-18 23:55:18 +08:00
Yeuoly 342d4060ff fix: add additional parameters to exists tools 2024-12-18 23:54:48 +08:00
Joel 289a040508 chore: merge 2024-12-18 17:54:18 +08:00
Joel d49e9890ba fix: file name text overflow not work 2024-12-18 16:49:11 +08:00
NFish fa3f8c5bb0 merge origin/feat/parent-child-retrival 2024-12-18 16:44:51 +08:00
Joel eead099c5e fix: not get extensions can select all types files 2024-12-18 16:38:16 +08:00
twwu 7185fd2d5a Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-18 15:03:12 +08:00
twwu 8d9a2d6d99 fix: Enhance components with display names and ref forwarding; fix preview and edit slice style issue 2024-12-18 14:47:33 +08:00
Joel ade6dd4b6f fix: delimiter not support empty and not escape 2024-12-18 14:25:56 +08:00
Joel 0006852b5b fix: parent child has no overlap 2024-12-18 14:13:59 +08:00
Joel 6ea333fb44 fix: child sparator not escape 2024-12-18 14:10:18 +08:00
Joel c22c010210 fix: empty no text 2024-12-18 13:57:29 +08:00
NFish 4e6db1f4fb fix: update parent child style 2024-12-18 11:46:41 +08:00
NFish 330cfaf6d6 Merge branch 'feat/parent-child-retrieval' of github.com:langgenius/dify into feat/parent-child-retrieval 2024-12-17 18:20:00 +08:00
NFish 827cffc4d9 fix: update dataset document processing style 2024-12-17 18:17:23 +08:00
Joel 8ee7e0a787 fix: text size 2024-12-17 18:10:44 +08:00
Joel de6b0670a3 chore: detail ui 2024-12-17 17:53:25 +08:00
Joel 39452274f8 chore: fix chunk detail spacing 2024-12-17 17:46:43 +08:00
Joel 4ef876db23 chore: use qa language 2024-12-17 17:35:50 +08:00
twwu a1abbedc13 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-17 16:42:17 +08:00
twwu a099e0a7e6 fix: Adjust layout and prevent default behavior in action buttons 2024-12-17 16:42:11 +08:00
Yeuoly 810ac6e1b2 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-17 15:50:13 +08:00
Yeuoly 05232d36f0 fix: add default values to WorkflowAppGenerator 2024-12-17 15:49:33 +08:00
Joel 1613eadbce chore: not free plan show auto disabled 2024-12-17 15:32:14 +08:00
twwu f2c087b805 fix: Fix FullScreenDrawer background color missing 2024-12-17 15:20:32 +08:00
twwu 5ba51fd7d2 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-17 14:29:41 +08:00
twwu f7c38db575 feat: enhance child segment list and segment card UI with improved styling and new props for EditSlice 2024-12-17 14:29:35 +08:00
Joel 4df52e7f95 fix: retriveal text left ui 2024-12-17 14:29:12 +08:00
AkaraChen 175f5fe6af fix: input number width & default value for child delimiter 2024-12-17 14:12:34 +08:00
NFish 1e2ca1aa7b revert: checkbox style 2024-12-17 10:57:45 +08:00
NFish 642aab38fd Merge branch 'feat/parent-child-retrieval' of github.com:langgenius/dify into feat/parent-child-retrieval 2024-12-17 10:46:45 +08:00
NFish 84641b6fd6 Merge branch 'main' into feat/parent-child-retrieval 2024-12-17 10:46:17 +08:00
twwu 9006a744b9 feat: enhance segment management by adding new segment mutation and improving UI layout 2024-12-17 10:13:53 +08:00
NFish 493ec06e95 Merge branch 'feat/parent-child-retrieval' of github.com:langgenius/dify into feat/parent-child-retrieval 2024-12-17 09:45:24 +08:00
Yeuoly 040a6fbc5f fix: refresh token 2024-12-16 19:41:50 +08:00
Joel 7a82422187 chore: record ui 2024-12-16 18:33:07 +08:00
Joel 29c41bf8e8 fix: retrieval ui 2024-12-16 18:30:11 +08:00
twwu 777bba0c63 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-16 18:15:59 +08:00
twwu 4850a99ce5 feat: refactor docForm type to use ChuckingMode and improve UI for question/answer sections 2024-12-16 18:15:54 +08:00
zxhlyh 9f90d70b38 merge feat/plugins 2024-12-16 18:06:06 +08:00
Joel e418cf30f5 chore: hiting test header ui 2024-12-16 18:05:02 +08:00
nite-knite 6da7efaa1d feat: update dataset embedding error message display 2024-12-16 18:04:20 +08:00
zxhlyh 04054954c5 Merge branch 'main' into feat/plugins 2024-12-16 17:55:52 +08:00
NFish a01a28997e fix: update datasource Step1 style 2024-12-16 17:54:48 +08:00
zxhlyh 672843dcab feat: marketplace list more link 2024-12-16 17:39:07 +08:00
nite-knite e206866908 feat: update UI for dataset creation step three 2024-12-16 17:16:03 +08:00
twwu 14f14420e7 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-16 17:10:38 +08:00
twwu faa5b63ed4 feat: update background styles and add loading skeletons for document detail components 2024-12-16 17:10:33 +08:00
Joel 782845f1a7 fix: header text 2024-12-16 16:51:12 +08:00
JzoNg 4f8cdabef0 dark mode of model provider 2024-12-16 16:29:45 +08:00
Joel d5a90daa44 chore: retrieval test text 2024-12-16 15:56:16 +08:00
Joel 3f9acc7029 feat: hit testing support external 2024-12-16 15:51:47 +08:00
zxhlyh e792e91777 fix: model page 2024-12-16 14:56:55 +08:00
Yeuoly fd02c60498 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-16 14:29:05 +08:00
JzoNg d5cb9f0193 add help doc link of endpoint 2024-12-16 14:20:22 +08:00
Yeuoly 636dde94c7 fix: migrations 2024-12-16 14:17:39 +08:00
Yeuoly 75fe785d88 Merge branch 'main' into fix/chore-fix 2024-12-16 14:08:18 +08:00
Yeuoly a61da6cf95 fix: replace Enum with StrEnum 2024-12-16 13:40:02 +08:00
twwu 340a052d44 fix: update dependencies array in useMemo hooks 2024-12-16 12:49:06 +08:00
twwu d5cb3af293 feat: add horizontal divider above pagination in completed documents view 2024-12-16 12:15:01 +08:00
twwu fb4d980096 feat: add loading state to child segment list component 2024-12-16 11:46:08 +08:00
twwu cfde86252c Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-16 11:20:50 +08:00
twwu cea24acb0a feat: enhance child segment list with empty state handling and search result display 2024-12-16 11:20:37 +08:00
JzoNg 171cc88a0d merge main 2024-12-16 11:09:13 +08:00
Joel 487809cecd fix: checkox mix merge error 2024-12-16 11:04:39 +08:00
非法操作andJoel 66d7d7a9bc fix: change http node params from dict to list tuple (#11665) 2024-12-16 11:04:38 +08:00
非法操作andJoel ae45575226 feat: add grok-2-1212 and grok-2-vision-1212 (#11672) 2024-12-16 11:04:38 +08:00
782a24b04d fix: remove the unused QueueWorkflowPartialSuccessEvent handle in workflow (#11669)
Co-authored-by: Novice Lee <novicelee@NoviPro.local>
2024-12-16 11:04:38 +08:00
b96686c1f9 chore: translate i18n files (#11639)
Co-authored-by: douxc <7553076+douxc@users.noreply.github.com>
2024-12-16 11:04:38 +08:00
c1cf5f8d15 feat: log add trace id (#11599)
Co-authored-by: hobo.l <hobo.l@binance.com>
2024-12-16 11:04:38 +08:00
yihongandJoel 975743925e fix: _handle_workflow_run_partial_success args is wrong (#11562)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2024-12-16 11:04:38 +08:00
yihongandJoel d8fb14d5df fix: ExternalDatasetService.process_external_api wrong args (#11586)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2024-12-16 11:04:38 +08:00
yihongandJoel b8aa9a0162 fix: account.id should account_id (#11628)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2024-12-16 11:04:38 +08:00
Bowen LiangandJoel 108c1ec929 test: run vdb tests on TiDB Vector with docker in CI tests (#11645) 2024-12-16 11:04:38 +08:00
yihongandJoel 5e3edd2b1c fix: better error message for stream (#11635)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2024-12-16 11:04:38 +08:00
IWAI, MasaharuJoelIWAI, Masaharu <iwai_masaharu@funkit.co.jp>
0dfa34ebff Update translate to Japanese: natural Japanese expression (#11647)
Co-authored-by: IWAI, Masaharu <iwai_masaharu@funkit.co.jp>
2024-12-16 11:04:38 +08:00
yihongandJoel 294be849d5 fix: langfuse do not have created_at args and fix the typing in the file (#11648)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2024-12-16 11:04:38 +08:00
IWAI, MasaharuandJoel aff330945d fix: rename README filename: Japanese language code is 'JA' (#11651) 2024-12-16 11:04:38 +08:00
Junyan QinandJoel 1ebf66718e fix: remove unnecessary curly braces in wf api doc (#11658) 2024-12-16 11:04:38 +08:00
yihongandJoel 36aebac6af fix: filter bug for keywork cause code can not reach (#11666)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2024-12-16 11:04:38 +08:00
NFishandJoel e9e78487b5 Feat: new entry point for app creation (#10847) 2024-12-16 11:04:32 +08:00
Kevin9703andJoel bc82de83b7 fix: app log filter value error (#11624) 2024-12-16 11:02:47 +08:00
yihongandJoel 09184afba0 fix: split dir for opendal tests (#11627)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2024-12-16 11:02:47 +08:00
-LAN-andJoel 674dd13fbd chore(dependency): bump gunicorn to 23.0 (#11560)
Signed-off-by: -LAN- <laipz8200@outlook.com>
2024-12-16 11:02:47 +08:00
zxhlyhandJoel a594fd87b8 Fix/pdf preview in build (#11621) 2024-12-16 11:02:47 +08:00
Hiroshi FujitaandJoel df1f5f7851 feat(devcontainer): add alias to stop Docker containers (#11616) 2024-12-16 11:02:47 +08:00
yihongandJoel 96bb49aded ci: better print version for ruff to check the change (#11587)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2024-12-16 11:02:47 +08:00
JasonVVandJoel 6d1264af4e feat(model): add vertex_ai Gemini 2.0 Flash Exp (#11604) 2024-12-16 11:02:47 +08:00
crazywoolaandJoel cfd964880a fix: name of llama-3.3-70b-specdec (#11596) 2024-12-16 11:02:47 +08:00
84d966d0d8 Added new models and Removed the deleted ones for Groq #11455 (#11456)
Co-authored-by: crazywoola <427733928@qq.com>
Co-authored-by: Alok Shrivastwa <Alok.Shrivastwa@microland.com>
2024-12-16 11:02:47 +08:00
Warren ChenandJoel a926cd436f [ref] use one method to get boto client for aws bedrock (#11506) 2024-12-16 11:02:47 +08:00
76338175e8 chore: translate i18n files (#11577)
Co-authored-by: JzoNgKVO <27049666+JzoNgKVO@users.noreply.github.com>
2024-12-16 11:02:47 +08:00
yihongandJoel 561453b63f fix: support mdx files close #11557 (#11565)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2024-12-16 11:02:47 +08:00
JoeandJoel 39c678308b fix: change workflow trace id (#11585) 2024-12-16 11:02:47 +08:00
KVOJJJinandJoel 076bd1cf8d Feat: dark mode for logs and annotations (#11575) 2024-12-16 11:02:45 +08:00
880094cc7b Lindorm vdb (#11574)
Co-authored-by: jiangzhijie <jiangzhijie.jzj@alibaba-inc.com>
2024-12-16 11:00:37 +08:00
非法操作andJoel 3e6ff18e1b feat: add gemini-2.0-flash-exp (#11570) 2024-12-16 11:00:37 +08:00
yihongandJoel 9a55bd119e fix: better opendal tests (#11569)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2024-12-16 11:00:37 +08:00
liuzhenghuaandJoel ec1efe5d54 Fix: RateLimit requests were not released when a streaming generation exception occurred (#11540) 2024-12-16 11:00:37 +08:00
708c1a19a1 chore: translate i18n files (#11545)
Co-authored-by: zxhlyh <16177003+zxhlyh@users.noreply.github.com>
2024-12-16 11:00:37 +08:00
zxhlyhandJoel 974b88d63a fix: workflow continue on error doc link (#11554) 2024-12-16 11:00:37 +08:00
-LAN-andJoel 4762d9b02d feat: integrate opendal storage (#11508)
Signed-off-by: -LAN- <laipz8200@outlook.com>
2024-12-16 11:00:37 +08:00
72b1bed79d fix: iteration node in parallel mode token count error (#11539)
Co-authored-by: Novice Lee <novicelee@NoviPro.local>
2024-12-16 11:00:37 +08:00
14912b2a1d Feat: continue on error (#11458)
Co-authored-by: Novice Lee <novicelee@NovicedeMacBook-Pro.local>
Co-authored-by: Novice Lee <novicelee@NoviPro.local>
2024-12-16 11:00:37 +08:00
zxhlyhandJoel d1d76823d1 feat: workflow continue on error (#11474) 2024-12-16 11:00:37 +08:00
Yi XiaoandJoel 3b57b8c91f chore: update thai lang in app page (#11541) 2024-12-16 11:00:37 +08:00
TommyandJoel 1a1d35607c [Pixtral] Add new model ; add vision (#11231) 2024-12-16 11:00:37 +08:00
c82271af75 fix: Remove duplicate 'response_format' parameter from model YAML files (#11531)
Co-authored-by: zhangkunyuan <zhangkunyuan@cmhi.chinamobile.com>
2024-12-16 11:00:37 +08:00
Paul van OorschotandJoel 0b7b12b003 feat: Add llama-3.3 models for Groq (#11533) 2024-12-16 11:00:37 +08:00
yihongandJoel cbb21149e6 fix: better error message for url add external knowledge (#11537)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2024-12-16 11:00:37 +08:00
yihongandJoel 88df17694f Revert "fix: total tokens is wrong which is zero in inter way, close … (#11536) 2024-12-16 11:00:37 +08:00
yihongandJoel 602bd801c3 fix: can not start local by REMOTE_SETTINGS_SOURCE_NAME change it to … (#11535)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2024-12-16 11:00:37 +08:00
yihongandJoel a571914ffc fix: issue 11247 that Completion mode content maybe list or str (#11504)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2024-12-16 11:00:37 +08:00
Wei MingzhiandJoel e2a3c2e9da Remove the processing of single quote when testing API tools. (#11390) 2024-12-16 11:00:37 +08:00
非法操作andJoel b76cee7ad8 chore: LOCAL_FILE also try to use remote_url as Prompt message (#11443) 2024-12-16 11:00:37 +08:00
e8f46bffde Msg file preview (#11466)
Co-authored-by: crazywoola <427733928@qq.com>
Co-authored-by: crazywoola <100913391+crazywoola@users.noreply.github.com>
2024-12-16 11:00:37 +08:00
barabicuandJoel e299232a19 chore: fix typo in Japanese localization (#11502) 2024-12-16 11:00:37 +08:00
문정현andJoel 08a4d6d67f chore : fix translation Typo in ko-KR localization (#11509) 2024-12-16 11:00:37 +08:00
-LAN-andJoel 0deb19e800 fix(app_generator_service): overload type hints (#11507)
Signed-off-by: -LAN- <laipz8200@outlook.com>
2024-12-16 11:00:37 +08:00
orangeclkandJoel 5190cac072 feat: add siliconflow qwq and llama3.3 model (#11492) 2024-12-16 11:00:37 +08:00
60470414fa feat:add apollo configuration to load env file (#11210)
Signed-off-by: -LAN- <laipz8200@outlook.com>
Co-authored-by: huanshare <liuhuan101@longfor.com>
Co-authored-by: -LAN- <laipz8200@outlook.com>
2024-12-16 11:00:37 +08:00
Yingchun LaiandJoel 062a57589b fix: add the missing abab6.5t-chat model of Minimax (#11484) 2024-12-16 11:00:37 +08:00
-LAN-andJoel 7f5bda81e5 chore: bump version to 0.13.2 (#11489)
Signed-off-by: -LAN- <laipz8200@outlook.com>
2024-12-16 11:00:37 +08:00
Hash BrownandJoel 61fd1947ff fix: cannot close notification manually (#11490) 2024-12-16 11:00:35 +08:00
JyongandJoel 19e13d89bc improve message clean logic (#11487) 2024-12-16 10:59:56 +08:00
-LAN-andJoel 186e39fd2f refactor(iteration_node): use Sequence and Mapping in parameters (#11483)
Signed-off-by: -LAN- <laipz8200@outlook.com>
2024-12-16 10:59:56 +08:00
eabf59f00d Fix the token count at the iteration node (#11235)
Co-authored-by: -LAN- <laipz8200@outlook.com>
2024-12-16 10:59:56 +08:00
83a5dcffac fix: tags could not be saved when the Workflow Tool was created (#11481)
Co-authored-by: zhaobs <zhaobs@cailian.net>
2024-12-16 10:59:56 +08:00
kurokoboandJoel e11a876f79 feat: add 'Open in Explore' link for each apps on studio (#11402) 2024-12-16 10:59:56 +08:00
Muneyuki NoguchiandJoel dcac973adc Fix the Japanese translation for 'Detail' (#11476) 2024-12-16 10:59:56 +08:00
Yi XiaoandJoel 45bdeb79f8 feat: ifelse condition variable editable after selection (#11431) 2024-12-16 10:59:56 +08:00
Charlie.WeiandJoel af9060e238 Refactor: Remove redundant style and simplify Mermaid component (#11472) 2024-12-16 10:59:56 +08:00
xiandan-erizoandJoel 160c229304 Update ext_redis.py (#11214) 2024-12-16 10:59:56 +08:00
3652d71ac6 remove mermail render cache (#11470)
Co-authored-by: Gimling <huangjl@ruyi.ai>
2024-12-16 10:59:56 +08:00
Trey DongandJoel 3eac339dd3 fix(api): throw error when notion block can not find (#11433) 2024-12-16 10:59:56 +08:00
yihongandJoel 4208e35e54 fix: unit tests env will need clear too (#11445)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2024-12-16 10:59:56 +08:00
Kazuki TakamatsuandJoel 9dccb51fd0 Fix model provider of vertex ai (#11437) 2024-12-16 10:59:56 +08:00
Hash BrownandJoel 65262b3ab7 fix: cannot upload animated webp image as app icon (#11453) 2024-12-16 10:59:56 +08:00
非法操作andJoel 8ed235fa0b feat: support json_schema for ollama models (#11449) 2024-12-16 10:59:56 +08:00
非法操作andJoel 7bbb745e33 feat: add gemini exp 1206 (#11444) 2024-12-16 10:59:56 +08:00
非法操作andJoel 994b7a6603 feat: add zhipu glm_4v_flash (#11440) 2024-12-16 10:59:56 +08:00
Hash BrownandJoel 26dee2e885 style: EmojiPicker component top padding (#11452) 2024-12-16 10:59:56 +08:00
24d43dceb4 fix: issue #10596 by making the iteration node outputs right (#11394)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
Signed-off-by: -LAN- <laipz8200@outlook.com>
Co-authored-by: -LAN- <laipz8200@outlook.com>
2024-12-16 10:59:56 +08:00
be9f58d065 fix(document_extractor): pptx file type and missing metadata_filename UnstructuredIO (#11364)
Co-authored-by: Julian Huynh <julian.huynh@immersio.io>
2024-12-16 10:59:56 +08:00
KVOJJJinandJoel ffd1343a09 Fix: compatible with outputs data structure (#11432) 2024-12-16 10:59:56 +08:00
JyongandJoel 898ea9bf0f update tidb batch get endpoint to basic mode (#11426) 2024-12-16 10:59:55 +08:00
JyongandJoel 269698d8ce fix external retrieval without segment id (#11423) 2024-12-16 10:59:55 +08:00
shirochanandJoel 1e5a9acc74 FEAT: cohere rerank 3.5 model added (#11289) 2024-12-16 10:59:55 +08:00
MatsudaandJoel 8fd0eaf5b7 fix(model_runtime): add vision to Amazon Nova Lite and Pro (#11398) 2024-12-16 10:59:55 +08:00
crazywoolaandJoel e98e3e1f17 use md table systax in pr template (#11412) 2024-12-16 10:59:55 +08:00
kurokoboandJoel 083af2a044 fix: add elkjs (#11404) 2024-12-16 10:59:55 +08:00
huayaoyue6andJoel 8ae566e8fc fix: update DocumentIsPausedError (#11405) 2024-12-16 10:59:55 +08:00
Charlie.WeiJoelluowei <glpat-EjySCyNjWiLqAED-YmwM>crazywoolacrazywoola
e562cdc72e Update mermaid (#11356)
Co-authored-by: luowei <glpat-EjySCyNjWiLqAED-YmwM>
Co-authored-by: crazywoola <427733928@qq.com>
Co-authored-by: crazywoola <100913391+crazywoola@users.noreply.github.com>
2024-12-16 10:59:55 +08:00
e81d830a56 chore: translate i18n files (#11389)
Co-authored-by: JzoNgKVO <27049666+JzoNgKVO@users.noreply.github.com>
2024-12-16 10:59:55 +08:00
KVOJJJinandJoel b68de4fa6d Fix: support file download in workflow result (#11338) 2024-12-16 10:59:15 +08:00
-LAN-andJoel 8eb888f7d6 chore: bump version to 0.13.1 (#11382)
Signed-off-by: -LAN- <laipz8200@outlook.com>
2024-12-16 10:59:15 +08:00
Warren ChenandJoel c99b822ca5 [fix] rename yaml files to fit windows (#11379) 2024-12-16 10:59:15 +08:00
Yi XiaoandJoel ed234e82d0 fix: empty object (conversation variable) editable (#11352) 2024-12-16 10:59:15 +08:00
yihongandJoel 824877dd5f fix: some typos using typos (#11374)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2024-12-16 10:59:15 +08:00
Yi XiaoandJoel a62892ccdb fix: bg typo in variable aggregator node (#11376) 2024-12-16 10:59:15 +08:00
0bae1c6cb6 [feat] Add AWS Bedrock rerank (#11349)
Co-authored-by: crazywoola <427733928@qq.com>
2024-12-16 10:59:15 +08:00
twwu 6a02076c54 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-16 10:55:19 +08:00
twwu 022fa663c5 fix: improve memoization for document detail processing modes 2024-12-16 10:55:13 +08:00
Joel ab7df47768 fix: handle show child trunck 2024-12-16 10:26:52 +08:00
Yeuoly fa03ba23bb Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-15 18:12:43 +08:00
Yeuoly 93c3699128 feat: add label to agent log 2024-12-15 18:12:29 +08:00
Yeuoly a48608dd9b Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-13 22:53:20 +08:00
Yeuoly 6357450a7a feat: support hidden parameters 2024-12-13 22:53:08 +08:00
Yeuoly ecb5e85ca4 fix: unbound variable 2024-12-13 20:21:47 +08:00
Yeuoly 92e02c1d0c fix: avoid sending email to unauth users 2024-12-13 20:21:02 +08:00
Yeuoly 2e2d1659ca feat: support whitelist 2024-12-13 20:09:05 +08:00
Yeuoly 3dd6d96b5a Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-13 19:51:28 +08:00
Yeuoly 6339706c68 fix: ruff reformatter 2024-12-13 19:51:09 +08:00
Yeuoly 65a4cb769b refactor: tool entities 2024-12-13 19:50:54 +08:00
twwu 8f56c6a7fa Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-13 17:39:44 +08:00
twwu f1782664b6 feat: add empty state handling and translations for segment list 2024-12-13 17:38:26 +08:00
AkaraChen 031c2ad899 chore: update pnpm lock 2024-12-13 17:27:04 +08:00
AkaraChen fe2d60dfc9 fix: option card gradient & tailwind config 2024-12-13 15:47:29 +08:00
nite-knite 7d673e7f14 feat: dataset creation UI tinkering 2024-12-13 15:28:17 +08:00
AkaraChen 8f178290be fix: preview document picker label overflow 2024-12-13 15:20:37 +08:00
AkaraChen f304976715 fix: create dataset step one next 2024-12-13 15:13:06 +08:00
AkaraChen b2322aca27 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-13 14:57:18 +08:00
AkaraChen 6dc20ee809 fix: unique key 2024-12-13 14:57:13 +08:00
twwu f7d6dbe90b fix: adjust layout and styling in child segment list component 2024-12-13 14:54:33 +08:00
twwu 44929133a4 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-13 14:45:39 +08:00
twwu a4c66e3659 feat: improve translation handling in segment components 2024-12-13 14:45:31 +08:00
AkaraChen ab76266993 chore: enable type intelligence for tailwind config 2024-12-13 14:43:52 +08:00
AkaraChen b0f34975d4 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-13 14:42:13 +08:00
AkaraChen 24975d475a fix: step 2 switch to economy 2024-12-13 14:41:57 +08:00
nite-knite 8de12ef1d7 feat: update dataset creation UI 2024-12-13 14:41:19 +08:00
JzoNg 463f5a34c6 dark mode for plugins 2024-12-13 14:06:07 +08:00
AkaraChen 2fb71dce50 feat: create datasets step two dark mode 2024-12-13 13:11:37 +08:00
JzoNg 5c98f1a5aa dark mode for tools 2024-12-13 13:10:29 +08:00
twwu 766f697f83 feat: navigate to document detail on selection in DocumentPicker 2024-12-13 10:30:48 +08:00
twwu 1641638523 refactor: reorganize BatchAction import paths and enhance child segment scrolling behavior 2024-12-13 10:12:43 +08:00
Yeuoly 11c4bf5574 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-13 00:06:09 +08:00
Yeuoly 63206a7967 fix: incorrect use of node execution id 2024-12-13 00:05:57 +08:00
Yeuoly 4cbaa6b77d Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-12 23:46:58 +08:00
Yeuoly 9a6f120e5c feat: support agent log event 2024-12-12 23:46:26 +08:00
Yeuoly d01f0278f4 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-12 19:16:31 +08:00
Yeuoly dedc1b0c3a refactor: agent strategy parameter 2024-12-12 19:16:06 +08:00
Yeuoly 8278c8a27e Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-12 18:27:58 +08:00
Yeuoly 46bb246ecc refactor: rename agent to agent strategy 2024-12-12 18:27:43 +08:00
Yeuoly 3c628d0c26 refactor: rename agent to agent strategy 2024-12-12 18:27:31 +08:00
zxhlyh 7727ec822a Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-12 17:29:55 +08:00
zxhlyh a0e999e438 feat: plugin add agent-strategy type 2024-12-12 17:29:25 +08:00
twwu a8254c29c5 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-12 17:14:44 +08:00
twwu 3dbd8f5d31 feat: enhance child segment list with total count and input value handling 2024-12-12 17:14:33 +08:00
AkaraChen 939f7f3e06 fix: cannot open in upload 2024-12-12 16:56:06 +08:00
AkaraChen 489015bd9e fix: update document name display to prevent overflow 2024-12-12 16:50:15 +08:00
AkaraChen 1b150d31a9 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-12 16:42:34 +08:00
AkaraChen 3fa33b09af fix: add truncation to document name display and update dataset form checks 2024-12-12 16:42:23 +08:00
twwu 5a1159f9ab feat: update child chunk handling and improve UI interactions 2024-12-12 15:33:54 +08:00
JzoNg 4aef5939f1 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-12 15:14:59 +08:00
JzoNg e0cc990fa5 fix: tool parameter form change 2024-12-12 15:12:41 +08:00
twwu c1d1960215 feat: enhance time formatting and add child segment detail component 2024-12-12 14:45:00 +08:00
Yeuoly 85caf51ad1 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-12 13:51:00 +08:00
Yeuoly c2983ecbb7 fix: rename stream to streaming 2024-12-12 13:50:34 +08:00
twwu fd339d51e2 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-12 13:39:50 +08:00
twwu 36778a4ebe feat: add and delete child chunks 2024-12-12 13:39:45 +08:00
AkaraChen 3f1b92a23f fix: data source web & notion 2024-12-12 13:37:36 +08:00
AkaraChen ac24163fb9 chore: change some color for dark mode 2024-12-12 13:13:08 +08:00
twwu a25a3ee1f7 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-11 18:38:05 +08:00
twwu 28987003fa refactor: simplify SegmentIndexTag usage and improve label prefix handling 2024-12-11 18:37:56 +08:00
Joel f2eeaba8d7 chore: remove useless test code 2024-12-11 18:23:52 +08:00
twwu db01c5c89d Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-11 18:18:06 +08:00
twwu 51f6a87aef feat: update translation files and improve segment index tag component 2024-12-11 18:15:30 +08:00
Joel d88bb70427 fix: loding and empty css 2024-12-11 18:13:56 +08:00
AkaraChen 4f6bc54280 fix: update file type casting in PreviewDocumentPicker 2024-12-11 18:05:05 +08:00
Joel 49a48910cd chore: hit result toggle btn 2024-12-11 18:02:16 +08:00
AkaraChen 3f6aee6c51 feat: economy hover effect & upload page 2024-12-11 18:01:02 +08:00
Joel f22c608c89 fix: tiny css problem 2024-12-11 17:48:22 +08:00
AkaraChen 41039f09bf fix: switch to parent child not use qualified 2024-12-11 16:55:11 +08:00
AkaraChen 6d689317ea Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-11 16:50:43 +08:00
AkaraChen f969dce345 feat: switch to high quan modal 2024-12-11 16:50:32 +08:00
Joel 599345879e feat: result ui 2024-12-11 16:34:52 +08:00
AkaraChen 9dce37bb24 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-11 15:45:14 +08:00
AkaraChen 149cfaafc5 feat: add switch to high quan dialog 2024-12-11 15:45:05 +08:00
Joel 17ae100342 chore: result main 2024-12-11 15:15:04 +08:00
Joel 361a007f42 feat: tags 2024-12-11 14:42:14 +08:00
Joel b8ced5102c feat: new retrieval result ui 2024-12-11 14:30:01 +08:00
zxhlyh 5b3112a137 fix: model page empty 2024-12-11 14:10:28 +08:00
twwu 4017c65c1f Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-11 14:00:27 +08:00
twwu 8518c1ae8c feat: add regeneration confirmation and success messages in translation files 2024-12-11 14:00:21 +08:00
twwu 033ce47d01 feat: add Dot and Tag components for enhanced UI representation 2024-12-11 13:31:21 +08:00
AkaraChen 70d1d03106 fix: not use css var 2024-12-11 11:06:20 +08:00
AkaraChen 11ee45f1c2 fix: default value not match prd 2024-12-11 11:03:03 +08:00
Joel 16d8bdfc78 chore: hit result item temp 2024-12-10 18:36:45 +08:00
Joel 14c8297e36 chore: fix setting text 2024-12-10 18:36:45 +08:00
twwu 8baaf7c84e Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-10 18:01:43 +08:00
twwu b4a6ec077f feat: add functionality to regenerate child chunks and enhance UI components for segment management 2024-12-10 18:01:38 +08:00
AkaraChen 27f5738c55 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-10 17:32:43 +08:00
AkaraChen 5fa0fc4858 fix: dataset settings 2024-12-10 17:32:31 +08:00
Joel 87e284ef75 feat: no linked app ui 2024-12-10 17:19:05 +08:00
Joel dd23f1093b feat: linked app new ui 2024-12-10 16:13:12 +08:00
Joel 77185d9617 feat: dataset info to new ui 2024-12-10 16:13:12 +08:00
AkaraChen f894fb05c1 fix: retrive config cannot enable rerank 2024-12-10 16:04:42 +08:00
zxhlyh 1272cf8fe7 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-10 15:52:16 +08:00
zxhlyh 35fb9099e3 fix: model page 2024-12-10 15:51:55 +08:00
zxhlyh 3803989480 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-10 14:58:38 +08:00
twwu 6055e27050 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-10 14:16:49 +08:00
twwu 09cdb573c7 feat: enhance NewSegmentModal with add another option and improve cancel behavior 2024-12-10 14:16:43 +08:00
Joel 430de3108b chore: remove isloading break ui 2024-12-10 14:15:14 +08:00
Joel d1743ee3e5 feat: auto disabled api 2024-12-10 14:12:03 +08:00
Joel 335e57f3c9 feat: auto disable document ui 2024-12-10 14:12:03 +08:00
zxhlyh c51c032334 fix: dsl check 2024-12-10 14:11:34 +08:00
zxhlyh 5825c101c9 fix: marketplace exclude 2024-12-10 13:37:02 +08:00
twwu ae3eae413f feat: add LayoutRight2LineMod icon component and update document detail 2024-12-10 13:12:05 +08:00
twwu 89345e5c5a Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-10 11:32:02 +08:00
twwu 65a9cac099 feat: add new translations and enhance segment management features 2024-12-10 11:31:56 +08:00
Yeuoly 80b3de5c4f Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-10 02:21:56 +08:00
Yeuoly 527c1cf608 fix: deduplicate provider id 2024-12-10 02:21:46 +08:00
Yeuoly 6868ee5431 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-10 00:23:08 +08:00
Yeuoly 93786f516c apply ruff 2024-12-10 00:22:54 +08:00
Yeuoly a175d6b2d7 feat: agent management 2024-12-10 00:22:41 +08:00
Yeuoly 054b59c702 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-09 23:26:38 +08:00
Yeuoly 296fd82bbf fix: agent node 2024-12-09 23:26:16 +08:00
Yeuoly ff81d12426 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-09 23:02:50 +08:00
Yeuoly 4ccd571364 fix: ruff 2024-12-09 23:02:25 +08:00
Yeuoly ae72514cb4 feat: support agent node 2024-12-09 23:02:11 +08:00
Joel 4c1bf96b14 fix: node build out of memory 2024-12-09 18:26:09 +08:00
Joel 54f03c5c78 fix: node build out of memory 2024-12-09 18:15:06 +08:00
AkaraChen 14934c0610 feat: file preview in step two 2024-12-09 18:10:56 +08:00
Joel 0d64a35fb6 chore: refact retry btn 2024-12-09 17:34:57 +08:00
twwu aa0d587516 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-09 16:56:58 +08:00
twwu 55ed41520f feat: enhance batch action confirmation and segment management 2024-12-09 16:55:13 +08:00
Joel ccdb3c5931 fix: deleting problem 2024-12-09 16:29:33 +08:00
Yeuoly 6e798fad34 fix: add pnpm lock 2024-12-09 16:17:33 +08:00
Yeuoly e401d917ac fix 2024-12-09 16:16:56 +08:00
Yeuoly 04d3abd754 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-09 16:13:33 +08:00
Yeuoly 16b49ac436 Merge branch 'main' into fix/chore-fix 2024-12-09 16:08:19 +08:00
AkaraChen 01e363f33f Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-09 15:43:49 +08:00
AkaraChen 20a2e76f40 feat: file selector for preview in parent child 2024-12-09 15:43:34 +08:00
Yeuoly c377eb8c28 fix: unbound variable in tool node 2024-12-09 15:43:01 +08:00
Joel 82e2b68d9e feat: preview document picker 2024-12-09 15:42:19 +08:00
twwu 12c791149c Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-09 11:46:24 +08:00
twwu 1c5464dbef feat: add pagination for chunk list 2024-12-09 11:46:18 +08:00
AkaraChen 2d66077ed3 fix: option card style 2024-12-09 10:18:04 +08:00
AkaraChen ec1c03f0a3 fix: i18n & option card props 2024-12-09 10:08:19 +08:00
AkaraChen 3d283a11b6 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-06 23:01:15 +08:00
AkaraChen cc2a9cdf37 wip: refactor 2024-12-06 22:33:53 +08:00
Joel b7472c7ab0 chore: change batch url 2024-12-06 18:29:26 +08:00
twwu c541d4aaa8 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-06 18:21:05 +08:00
twwu b0a4819ec1 feat: enhance translations and UI components for segment management 2024-12-06 18:20:59 +08:00
Joel d1d9315f05 chore: list page color to css vars 2024-12-06 17:21:27 +08:00
twwu c9114d171e Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-06 17:19:25 +08:00
twwu 1546859bae feat: add child segment response type and enhance dataset components with improved translations and UI updates 2024-12-06 17:18:29 +08:00
StyleZhang b448900bb8 merge feat/plugins 2024-12-06 16:58:42 +08:00
StyleZhang 69daf4a027 merge main 2024-12-06 16:56:42 +08:00
Yeuoly 1ce7990df4 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-06 16:47:40 +08:00
Yeuoly 337eff2b79 Merge branch 'main' into fix/chore-fix 2024-12-06 16:45:25 +08:00
AkaraChen dfebcd0ea7 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-06 16:16:35 +08:00
AkaraChen 6383a64419 fix: step 2 preview ui padding 2024-12-06 16:16:30 +08:00
JzoNg 3bc9ddb006 fix mutation of model credentials update 2024-12-06 16:05:06 +08:00
JzoNg ea2862e435 fix style of boolean form of model parameters 2024-12-06 16:05:06 +08:00
StyleZhang ca3d96e5f4 fix: tool list 2024-12-06 15:42:02 +08:00
Joel 570bf75698 feat: support multi 2024-12-06 15:22:31 +08:00
AkaraChen 07f0140d10 feat: preview parent child chunk in create step 2 2024-12-06 15:20:14 +08:00
Joel 6748b50bf1 feat: use query to handle api and remove old api service 2024-12-06 14:26:38 +08:00
AkaraChen 6e38b523c9 wip: create datasets 2024-12-06 13:40:34 +08:00
AkaraChen a893309b73 wip: create datasets 2024-12-06 13:27:32 +08:00
Joel f3cfcb757e feat: document update change to batch api 2024-12-06 11:53:28 +08:00
Joel 91666c4394 chore: action i18n and remove confirm 2024-12-06 11:20:03 +08:00
Yeuoly fbcd4fe1f7 fix: use default_factory for list fields 2024-12-05 20:58:03 +08:00
Yeuoly b7ac287fec fix: use default_factory for list fields 2024-12-05 20:57:30 +08:00
Joel 768073ddac feat: batch action ui 2024-12-05 17:34:40 +08:00
twwu 734659c873 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-05 15:44:58 +08:00
twwu b59e95785c feat: enhance DocumentDetail and Completed components with child segment handling and improved layout 2024-12-05 15:44:53 +08:00
AkaraChen 9f8cf03155 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-05 15:32:59 +08:00
AkaraChen 0361bf00d1 fix: option card overflow clip cause language selector hidden 2024-12-05 15:32:34 +08:00
Joel 1cfb938a7b feat: support check item 2024-12-05 15:29:42 +08:00
Joel cae8ce5a1e fix: list add paging 2024-12-05 15:29:42 +08:00
Yi d6dea67947 apply the skeleton component to the Plugin loading card 2024-12-05 15:27:47 +08:00
Yi b8f9747849 Merge branch "main" into feat/plugins 2024-12-05 15:08:09 +08:00
AkaraChen 2417699e85 feat: new qa setting ui 2024-12-05 15:00:54 +08:00
StyleZhang f038eb2390 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-05 14:55:32 +08:00
StyleZhang 0e70e72594 fix: marketplace list 2024-12-05 14:54:20 +08:00
Yeuoly 243d160242 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-05 14:49:04 +08:00
Yeuoly c1a85b0208 fix: add default value to plugin permission field 2024-12-05 14:48:34 +08:00
Yi 0e419a7a16 feat: move linear gradient bg to common config 2024-12-05 14:44:45 +08:00
Joel 8a8fc7ab50 feat: finish add chunk mode 2024-12-05 14:08:45 +08:00
Joel 1578dc50ef feat: add chunking mode 2024-12-05 11:40:46 +08:00
twwu 78fff31e61 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-05 11:13:20 +08:00
twwu b18eb58770 feat: implement ChildSegmentList component and integrate it into SegmentCard for displaying child chunks 2024-12-05 11:13:14 +08:00
twwu 52ba180bf4 feat: add SegmentDetail component for displaying and editing segment information 2024-12-05 11:11:57 +08:00
AkaraChen 8541153b15 merge main 2024-12-05 10:57:27 +08:00
AkaraChen 0185fb3369 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-05 10:40:32 +08:00
AkaraChen 5bf6cd242d wip: qa mode 2024-12-05 10:40:27 +08:00
twwu f8d6d5a6a9 refactor: replace DocumentContext with useDocumentContext for improved context management 2024-12-05 10:12:02 +08:00
twwu 7200dd42d3 refactor: update batch action component props and change id type in ChildChunkDetail 2024-12-05 09:49:37 +08:00
Yeuoly df68b6befa Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-04 19:26:23 +08:00
Yeuoly 01efdee1dd fix: support other file types for Tool 2024-12-04 19:26:01 +08:00
Yeuoly 3d3a42945f Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-04 19:02:50 +08:00
Yeuoly 0af9c4fd9d chore: reformat 2024-12-04 19:02:28 +08:00
Yeuoly ee38bd8817 refactor: check dependencies 2024-12-04 19:01:54 +08:00
twwu 44989ae97c Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-04 18:11:10 +08:00
twwu 0ac5e53c2e fix: refactor GitHub releases fetching to improve error handling and format response 2024-12-04 18:08:25 +08:00
Joel 44b0039e8b fix: install plugin type show error 2024-12-04 18:06:00 +08:00
AkaraChen 4048eff3ab chore: remove twc 2024-12-04 17:37:12 +08:00
twwu becdca24df fix: enhance GitHub releases fetching with optional authentication 2024-12-04 16:49:49 +08:00
AkaraChen 8289175bfa style: fix component naming 2024-12-04 16:23:43 +08:00
AkaraChen 539050c56b style: fix component naming 2024-12-04 16:16:00 +08:00
AkaraChen 90b407ecc8 feat: loading & empty state for step 2 2024-12-04 16:07:25 +08:00
Joel 9fc0e658ad merge 2024-12-04 16:05:11 +08:00
Yeuoly e5e8277c2d Merge remote-tracking branch 'origin/feat/plugins' into dev/plugin-deploy 2024-12-04 15:40:39 +08:00
Yeuoly 86291c13e4 Merge branch 'main' into fix/chore-fix 2024-12-04 15:34:39 +08:00
AkaraChen 1df3f4aad3 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-04 14:34:38 +08:00
twwu 8d74eb4946 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-12-04 14:24:54 +08:00
twwu 388d7918f3 feat: add translation for chunks and new icons; update checkbox styles; add new segment list and segment card 2024-12-04 14:24:47 +08:00
AkaraChen 14f46308a9 chore: gen icon for selection icon 2024-12-04 14:10:17 +08:00
AkaraChen 629152ff2c feat: ui component finish for chunk preview 2024-12-04 11:52:05 +08:00
Joel 29d29f8731 fix: can not chosse const 2024-12-04 11:17:15 +08:00
Joel f634a4488f merge main 2024-12-04 11:06:00 +08:00
Yeuoly d5cf64f289 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-03 19:45:25 +08:00
Yeuoly 7679a57f18 fix: agent type errors 2024-12-03 19:44:57 +08:00
Yeuoly 9cb2a031ed Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-03 19:28:22 +08:00
Yeuoly dcf19549cb feat: move audio and webscraper back to dify 2024-12-03 19:27:57 +08:00
Yi fc2656b4b7 fix: workspace selector UI 2024-12-03 18:34:18 +08:00
StyleZhang b858533a57 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-03 18:04:11 +08:00
StyleZhang d6a4cbc6cc fix: marketplace list 2024-12-03 18:03:39 +08:00
AkaraChen bebad5cbdd refactor: step 2 2024-12-03 17:26:45 +08:00
Yeuoly c51fa7a440 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-03 16:52:09 +08:00
Yeuoly 574a6c1ded fix: add extension, filename and size to PluginFileEntity 2024-12-03 16:51:51 +08:00
Yeuoly e6fcf06e59 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-03 16:29:02 +08:00
Yeuoly c34877aecf fix: update tool provider credentials 2024-12-03 16:28:36 +08:00
Yi 1e2ee61f6a feat: add version check before Plugin install from GitHub 2024-12-03 15:47:45 +08:00
AkaraChen dfdc4ed3b1 refactor: step 2 2024-12-03 15:23:51 +08:00
AkaraChen a77aa169b4 refactor: step 2 2024-12-03 14:43:15 +08:00
StyleZhang 66b79ee323 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-03 14:35:36 +08:00
StyleZhang ab9a177c90 fix: marketplace list 2024-12-03 14:34:44 +08:00
AkaraChen 94eb069a97 refactor: step 2 2024-12-03 14:34:18 +08:00
AkaraChen c960f78035 refactor: step 2 2024-12-03 14:14:37 +08:00
nite-knite 8b28ed589c feat: update translation for bundle 2024-12-03 13:43:13 +08:00
AkaraChen 90421b5fb5 feat: preview container components 2024-12-03 13:39:27 +08:00
Yeuoly 1dad2fdaaf Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-02 22:00:05 +08:00
Yeuoly 632b2bac2a fix: invoke-email 2024-12-02 21:59:52 +08:00
Yeuoly dbc555f698 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-02 21:26:12 +08:00
Yeuoly 77a62f33b3 fix: Lookup errors for contextvars used in ToolManager 2024-12-02 21:25:47 +08:00
Yeuoly 78a0c3c13c Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-02 21:08:53 +08:00
Yeuoly ad899844a1 fix: workflow loads tool provider icon 2024-12-02 21:08:36 +08:00
nite-knite 3232a45ec4 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-02 18:00:09 +08:00
nite-knite 3b1211d6bc chore: bump cross-spawn from 7.0.3 to 7.0.6 2024-12-02 17:54:39 +08:00
nite-knite 7bd3f2b932 feat: update description for API endpoints configuration 2024-12-02 17:41:52 +08:00
Yeuoly 5abbe76ca0 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-12-02 16:51:57 +08:00
Yeuoly b10d6051ba fix: summary and create_file_by_url 2024-12-02 16:51:37 +08:00
JzoNg 86f45d7e25 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-12-02 16:13:31 +08:00
Yeuoly e23d322c1c Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-29 18:20:59 +08:00
Yeuoly fb44cd87e7 fix: image url message 2024-11-29 18:20:36 +08:00
Yeuoly 48c9a25393 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-29 16:49:18 +08:00
Yeuoly 89af726985 fix: cot agent 2024-11-29 16:48:39 +08:00
Yeuoly 8266bf6fa8 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-29 16:17:48 +08:00
Yeuoly 6f2d5ff099 fix: add tenant_id to invoke tts 2024-11-29 15:59:07 +08:00
Joel b78ab0bd69 fix: other install error 2024-11-29 15:18:07 +08:00
Joel 84cad5969e fix: not handleinstall error 2024-11-29 15:09:23 +08:00
Yeuoly f36a50ad09 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-29 14:09:54 +08:00
Yeuoly 687455ca31 fix: tool file id 2024-11-29 14:09:34 +08:00
Joel 35ef874867 fix: detect is same packege use uniqid 2024-11-29 10:56:58 +08:00
Yeuoly df67200e18 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-28 20:44:58 +08:00
Yeuoly 8c5928da2f fix: unify error handling 2024-11-28 20:44:06 +08:00
Yeuoly d409d30ee5 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-28 19:35:48 +08:00
Yeuoly 772009115d fix: keep process_data with None if not 2024-11-28 19:35:30 +08:00
Yeuoly 5df52b33d7 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-28 19:09:27 +08:00
Yeuoly 0452dfd029 fix: missing tool invoke messages 2024-11-28 19:09:04 +08:00
Joel 47579c86e6 fix: from marketplace install and update bundle 2024-11-28 18:47:06 +08:00
Joel 32619bd05e fix: install bunlde support update 2024-11-28 18:26:18 +08:00
Yeuoly e79dcf93fe Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-28 18:24:19 +08:00
Yeuoly eead6abe85 fix: tool image url response 2024-11-28 18:23:28 +08:00
JzoNg 6bd483030f Merge branch 'feat/plugins' into dev/plugin-deploy 2024-11-28 17:49:43 +08:00
JzoNg 6a500edf4d fix: loading of credential form 2024-11-28 17:48:28 +08:00
JzoNg adba60d067 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-11-28 17:30:56 +08:00
JzoNg be7fa93ffc fix: modify tip of default embedding model 2024-11-28 17:27:21 +08:00
JzoNg 3bcd470ec6 fix: authorization in debugging plugin 2024-11-28 17:27:21 +08:00
JzoNg 73825c59e4 fix: crash of tool authorization in agent 2024-11-28 17:27:21 +08:00
JzoNg 5f76975e12 fix: icon of tool provider in agent 2024-11-28 17:27:21 +08:00
JzoNg 3ddb3d2bff fix: deleted tools in agent 2024-11-28 17:27:21 +08:00
JzoNg a70eda6c45 add loading for auth modal 2024-11-28 17:27:21 +08:00
Yeuoly 1858e523f1 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-28 17:12:55 +08:00
Yeuoly 5c6d919a4a fix: handle detailed error type 2024-11-28 17:12:29 +08:00
NFish 42cdc55db1 fix: do not show error tooltip if http status code is 401 2024-11-28 16:04:19 +08:00
NFish a76d0a09b6 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-28 16:03:05 +08:00
AkaraChen 11679dc68a feat: child chunk component for dataset 2024-11-28 15:18:56 +08:00
Joel 51f0f21a47 chore: not load updateInfo can not install 2024-11-28 14:30:31 +08:00
Joel 073e847524 fix: installed 2024-11-28 14:13:43 +08:00
Joel 3e601c4ef5 feat: local support upgrade 2024-11-28 14:09:05 +08:00
Joel fba468e8ad fix: handle install the same version 2024-11-28 13:50:04 +08:00
twwu d1c3c26dc7 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-11-28 13:37:20 +08:00
twwu 32df9d6e00 feat: add segment management hooks for enabling, disabling, and deleting segments 2024-11-28 13:37:12 +08:00
Joel f40b212b04 feat: support update if installed from marketplace 2024-11-28 12:00:12 +08:00
StyleZhang 9d8445c758 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-11-28 11:27:13 +08:00
StyleZhang 37eee7be24 fix: model provider page marketplace 2024-11-28 11:26:45 +08:00
Joel 99942b26e6 chore: support install hide button 2024-11-28 10:40:33 +08:00
AkaraChen 25bccd52c2 feat: child chunk component for dataset 2024-11-28 10:36:24 +08:00
AkaraChen 521ab30bba fix: data processing form layout padding 2024-11-28 10:20:08 +08:00
Joel cc64419c84 feat: use new file icon 2024-11-27 17:57:28 +08:00
Joel e27568f0c7 fix: not add datasetid to picker 2024-11-27 16:52:10 +08:00
Joel b7b49daff8 feat: add picker logic 2024-11-27 16:48:40 +08:00
StyleZhang 9302a5fac8 merge feat/plugins 2024-11-27 16:15:57 +08:00
StyleZhang d4cda69b0e feat: marketplace add exclude 2024-11-27 16:14:15 +08:00
Joel 71e285c490 feat: add document file select 2024-11-27 15:52:58 +08:00
Yeuoly b1f2fc3cf4 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-27 14:49:00 +08:00
Yeuoly e39eddab03 fix: change to use convert_stream_full_response 2024-11-27 14:48:44 +08:00
StyleZhang e145dba487 fix: dsl check 2024-11-27 14:30:47 +08:00
Joel e908ecab8f fix: add ui 2024-11-27 10:50:39 +08:00
AkaraChen f1655888ef fix: number input component 2024-11-27 10:29:16 +08:00
Yeuoly 3a18aaebd2 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-26 18:59:18 +08:00
Yeuoly db726e02a0 feat: support multi token count 2024-11-26 18:59:03 +08:00
Yeuoly 66d4de39b8 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-26 18:04:34 +08:00
Yeuoly e4b8220bc2 Merge branch 'main' into fix/chore-fix 2024-11-26 18:02:41 +08:00
Joel a98df0158e chore: document header 2024-11-26 17:26:20 +08:00
AkaraChen 378461bf8a Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-11-26 17:22:07 +08:00
AkaraChen e2c6ea3a3a chore: align design token 2024-11-26 17:22:02 +08:00
twwu 0c4e06e1c1 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-11-26 16:56:34 +08:00
twwu 1e4167427c refactor: update processing status UI and add new CSS variables for success and error states 2024-11-26 16:56:27 +08:00
AkaraChen e26a963163 fix: missing translation 2024-11-26 16:05:14 +08:00
AkaraChen 72ca69fb2a Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-11-26 15:38:03 +08:00
AkaraChen db1956ed54 feat: dataset creation form reset 2024-11-26 15:37:57 +08:00
Joel 9aceceda2c fix: css var value 2024-11-26 15:33:58 +08:00
AkaraChen 1843f6ccb6 refactor: input number component 2024-11-26 15:29:31 +08:00
AkaraChen b7d9987953 chore: align design token 2024-11-26 14:48:49 +08:00
Joel b8af4aead1 fix: update version show problem 2024-11-26 14:38:43 +08:00
AkaraChen b528b1e875 refactor: use css var 2024-11-26 14:33:40 +08:00
AkaraChen c4aa98e609 Merge branch 'main' into feat/parent-child-retrieval 2024-11-26 14:18:56 +08:00
AkaraChen 4757db1b6b refactor: use css var 2024-11-26 14:18:42 +08:00
Joel d40f0e645c fix: install marketplace bundle title 2024-11-26 14:11:21 +08:00
Joel 4b77ced4ad fix: not show from market bundle package icon 2024-11-26 14:07:45 +08:00
Yeuoly d695ac4b24 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-26 14:00:28 +08:00
Yeuoly 08cfcb453c fix: missing marshal fields of leaked+dependencies 2024-11-26 13:59:52 +08:00
StyleZhang b84b0c8ba8 merge main 2024-11-26 11:38:37 +08:00
StyleZhang f47b32b26d fix: dsl 2024-11-26 11:10:53 +08:00
StyleZhang 102a42d24c Merge branch 'main' into feat/plugins 2024-11-26 11:08:30 +08:00
StyleZhang 00eb47384a merge main 2024-11-26 10:31:39 +08:00
StyleZhang 2041650cca merge main 2024-11-26 10:29:58 +08:00
StyleZhang a0873a956f merge main 2024-11-26 10:27:48 +08:00
Yeuoly 6e37eeabca Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-25 23:36:35 +08:00
Yeuoly 992e1eedde fix: export agent dsl 2024-11-25 23:36:19 +08:00
Yeuoly cdeda89801 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-25 23:22:52 +08:00
Yeuoly c2ce8e638e fix: deleted_tools 2024-11-25 23:22:17 +08:00
Joel df049564e8 feat: support install bundle from marketplace 2024-11-25 18:01:30 +08:00
Joel b93be49530 chore: support update show version 2024-11-25 18:01:29 +08:00
AkaraChen 1a6a28f650 feat: settings ui for database pre-preprocessing 2024-11-25 17:57:31 +08:00
StyleZhang 6bc37f4f00 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-11-25 17:54:45 +08:00
StyleZhang 57756b18e4 fix: plugin task 2024-11-25 17:54:28 +08:00
StyleZhang 2252821cae Merge branch 'feat/plugins' into dev/plugin-deploy 2024-11-25 17:33:25 +08:00
StyleZhang 8ad9ab40df fix: plugin task 2024-11-25 17:32:57 +08:00
Yeuoly e68fec0022 fix: linter 2024-11-25 17:20:43 +08:00
Yeuoly 69b61ef57b Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-25 17:19:51 +08:00
Yeuoly ba3659a792 feat: support delete all install tasks 2024-11-25 17:11:41 +08:00
Yeuoly 965fabd578 fix: rename dependencies 2024-11-25 16:57:38 +08:00
Yeuoly accbbae755 cleanup: remove get_interates 2024-11-25 16:47:49 +08:00
Yeuoly 49bd1a7a49 fix: riff 2024-11-25 16:44:08 +08:00
Yeuoly 5ff9cee326 Merge branch 'main' into fix/chore-fix 2024-11-25 15:37:19 +08:00
StyleZhang 4f54ac6ed6 fix: marketplace collection condition 2024-11-25 12:03:49 +08:00
Yeuoly dfc94cd7c2 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-22 20:04:42 +08:00
Yeuoly 200f9af5d8 optimize error messages 2024-11-22 20:04:20 +08:00
Yeuoly 1443fd6739 optimize: indexing-estimate 2024-11-22 19:39:07 +08:00
Yeuoly f69d5caa14 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-22 18:19:27 +08:00
Yeuoly e63ae36665 fix 2024-11-22 18:19:02 +08:00
Yeuoly cfa7c89dfe refactor: text-embedding interfaces to returns list[int] 2024-11-22 18:09:33 +08:00
StyleZhang a84f0e29a4 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-11-22 15:27:48 +08:00
StyleZhang 3263a6a5f5 fix: marketplace plugin tags i18n 2024-11-22 15:26:25 +08:00
JzoNg 27ea150a44 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-11-22 15:11:52 +08:00
JzoNg 506e5e0bc8 fix: plugin type 2024-11-22 14:53:20 +08:00
AkaraChen bba9301788 fix: layout overflow 2024-11-22 14:09:41 +08:00
AkaraChen 7881fb4d22 fix: layout overflow 2024-11-22 13:12:24 +08:00
JzoNg c768f8fdd1 fix: path of tool provider 2024-11-22 11:41:36 +08:00
twwu d45ce48932 fix: update theme imports in globals.css 2024-11-22 11:02:45 +08:00
Joel c6b1fecc21 merge 2024-11-22 11:01:00 +08:00
Joel 3e3ae989f0 chore: in tool file and files all support file and files 2024-11-22 10:54:22 +08:00
Joel 786f2d9bf6 chore: fix categoriesMap[category] undefined 2024-11-22 10:39:22 +08:00
twwu 85377d13fc Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-22 10:22:39 +08:00
twwu 51e04b45ec fix: update error icon z-index and upgrade react-query dependencies 2024-11-22 10:22:33 +08:00
JzoNg bd6c2e519c fix: corner mark 2024-11-22 09:09:35 +08:00
Joel 3f0b35d72e feat: install bundle from marketplace code 2024-11-21 18:22:11 +08:00
JzoNg f51336df08 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-11-21 18:13:11 +08:00
JzoNg 78c867b9a3 use plugin detail for builtin tool 2024-11-21 18:11:36 +08:00
JzoNg f213c8f393 fix: version switch 2024-11-21 18:11:36 +08:00
Joel 1b3f4f1f2a feat: support icon size 2024-11-21 18:00:13 +08:00
Joel c59c696df2 chore: add version type in marketplace return 2024-11-21 17:43:41 +08:00
Joel 8993a91f12 fix: upgrade sussces auto hide 2024-11-21 17:38:23 +08:00
JzoNg 02c5989612 recover api tool create card 2024-11-21 17:29:28 +08:00
JzoNg ac42ba880a fix: install handle of list refresh 2024-11-21 17:11:22 +08:00
Yeuoly b2fdf4f85f Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-21 17:00:28 +08:00
Yeuoly a6835ac64d fix: add detailed error messages 2024-11-21 17:00:00 +08:00
AkaraChen fdcee1cd45 feat: create top bar 2024-11-21 16:19:32 +08:00
JzoNg 56f573ecfb fix: update plugin handle 2024-11-21 15:35:39 +08:00
Joel 2560d3edae fix: bundle install title 2024-11-21 15:22:19 +08:00
Joel 351615fb98 fix: not the first time upload bundle error 2024-11-21 15:14:21 +08:00
twwu 13c62f83f4 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-11-21 15:13:21 +08:00
twwu c5b9a829c0 feat: update UI styles and enhance status indicator components 2024-11-21 15:13:16 +08:00
Yeuoly cc8117f02a Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-21 14:36:34 +08:00
Yeuoly 846c3faba7 fix: ruff 2024-11-21 14:36:01 +08:00
Yeuoly 7c74aaabcf Merge remote-tracking branch 'origin/feat/plugins' into dev/plugin-deploy 2024-11-21 14:35:14 +08:00
Joel 11ed86f2a8 feat: download package 2024-11-21 14:25:58 +08:00
JzoNg b01c18ae7f fix: version badge 2024-11-21 14:16:02 +08:00
Yeuoly a700b49461 fix: migration 2024-11-21 13:55:08 +08:00
Yeuoly 22df86fe8a fix: ruff 2024-11-21 13:53:08 +08:00
Yeuoly 24734009b9 Merge branch 'main' into fix/chore-fix 2024-11-21 13:52:28 +08:00
StyleZhang 84a3fe85c8 fix: marketplace card link 2024-11-21 13:50:26 +08:00
JzoNg 3efc6c5050 fix: github link 2024-11-21 13:42:06 +08:00
JzoNg 42a0534299 fix: locale of model provider 2024-11-21 13:18:33 +08:00
JzoNg eec193488d fix: detail link of plugin 2024-11-21 13:09:10 +08:00
JzoNg 021bc57cd4 empty of tool list 2024-11-21 12:43:18 +08:00
StyleZhang 022eda9e8b fix: tool providers 2024-11-21 12:03:53 +08:00
AkaraChen 6f3a1c9d72 feat: parent child state 2024-11-21 11:40:17 +08:00
Joel 2067092f52 feat: detail link in tools 2024-11-21 11:33:21 +08:00
Joel 000db07d29 feat: in tool install plugin 2024-11-21 11:16:05 +08:00
Joel 98ae34acd5 chore: support tags filter 2024-11-21 10:51:36 +08:00
StyleZhang 698e94856e fix: plugin task zindex 2024-11-21 08:42:36 +08:00
Yeuoly e05d7637ac Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-21 00:30:47 +08:00
Yeuoly 959d060a44 fix: remove signature verify 2024-11-21 00:30:28 +08:00
Joel 99ffe43e91 merge main 2024-11-20 18:24:03 +08:00
Yeuoly 4921e610af Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-20 18:12:45 +08:00
Yeuoly 4492295683 fix: remove plugin files 2024-11-20 18:12:12 +08:00
Joel 498222371c chore: parse marketplace bundle new api 2024-11-20 17:52:35 +08:00
twwu 13bb4aa721 Merge branch 'feat/parent-child-retrieval' of https://github.com/langgenius/dify into feat/parent-child-retrieval 2024-11-20 16:38:48 +08:00
twwu d0ef423e66 feat: enhance SegmentCard and SegmentAdd components with new DocumentTitle and improved UI elements 2024-11-20 16:38:38 +08:00
Joel 26288e71d3 fix: local bundle install 2024-11-20 16:32:20 +08:00
AkaraChen 8e1aef6120 feat: new dataset footer ui 2024-11-20 16:24:06 +08:00
JzoNg 19fb466074 fix: tool icon in app configure 2024-11-20 16:22:51 +08:00
JzoNg cd4eb9c3f1 fix: icon in model list 2024-11-20 16:22:51 +08:00
Joel 4ef0a3818f feat: can install bundle from local 2024-11-20 16:21:09 +08:00
twwu 77d6dbb3d0 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-20 15:31:03 +08:00
twwu e3b8926aef fix: correct fetched releases variable in version check and update dev script for debugging 2024-11-20 15:30:57 +08:00
AkaraChen 4657df17a9 revert: qa mode 2024-11-20 15:25:26 +08:00
Joel efb84ff03d fix: github install fix 2024-11-20 15:05:17 +08:00
AkaraChen 27ece2fb52 feat: most ui for create datasets
chore: upd
2024-11-20 14:55:59 +08:00
Joel 1846a7de73 fix: handle github item from data struct diffe 2024-11-20 14:48:38 +08:00
Joel 40d025052d fix: load package dsl error 2024-11-20 14:27:46 +08:00
Joel bb2914652a feat: finsh loading error comp 2024-11-20 13:56:32 +08:00
Joel e6a03f7a58 feat: loading error struct 2024-11-20 11:50:46 +08:00
JzoNg 386ee7b07b update model provider list after plugin installed 2024-11-20 11:49:20 +08:00
JzoNg 788f9de843 update model provider list after deleting plugin 2024-11-20 10:44:20 +08:00
AkaraChen ca4d0fb4cc feat: option card component
chore: upd
2024-11-20 10:13:40 +08:00
Joel 5947e38ea0 feat: install by local bundle change 2024-11-19 18:32:17 +08:00
Joel e151c2ee8c fix: when error can not install 2024-11-19 17:29:15 +08:00
Joel a093a48675 feat: show package item in bundle 2024-11-19 17:29:14 +08:00
Yeuoly 6c9f77092a Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-19 16:50:47 +08:00
Yeuoly 88fac0d898 fix: add tenant_id to plugin upload files url 2024-11-19 16:50:14 +08:00
StyleZhang f99f25ae02 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-11-19 16:43:38 +08:00
StyleZhang 27b1a51572 fix: marketplace collection label description 2024-11-19 16:43:13 +08:00
JzoNg a867040b88 fix icon of model provider 2024-11-19 16:26:23 +08:00
Joel 2e3442f74c feat: support local installed package 2024-11-19 16:04:31 +08:00
StyleZhang ba53900ec4 merge 2024-11-19 15:14:27 +08:00
StyleZhang 43d7a538dc feat: marketplace list url support search & tags 2024-11-19 15:08:54 +08:00
Joel c5c06c18f1 feat: can upload and parse bundle 2024-11-19 15:05:15 +08:00
Yeuoly ba148952bd Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-19 14:04:15 +08:00
Yeuoly 8b30099672 fix: convert backwards invocation into BaseBackwardsResponse 2024-11-19 14:03:40 +08:00
twwu 972eaa5948 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-19 11:20:23 +08:00
twwu 87b23a1fac feat: refactor GitHub releases fetching and update handling with improved error notifications 2024-11-19 11:20:17 +08:00
Yeuoly 44e9758549 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-18 17:21:32 +08:00
Yeuoly 97a3727962 fix: optimize DEFAULT-USER 2024-11-18 17:21:17 +08:00
AkaraChen 07174cf52c Revert "fix: dataset details"
This reverts commit 812fbab57b.
2024-11-18 15:41:31 +08:00
twwu d3fe6fd303 fix: display version from GitHub metadata if available 2024-11-18 11:57:31 +08:00
twwu 87ca20c047 feat: add version checking for GitHub releases and improve error handling 2024-11-18 11:54:51 +08:00
AkaraChen 07494459cc Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-18 11:23:49 +08:00
AkaraChen 812fbab57b fix: dataset details 2024-11-18 11:23:44 +08:00
JzoNg afdfc8c609 chore: enabled for useQuery 2024-11-18 11:02:37 +08:00
JzoNg 66f0e1209a switch version 2024-11-17 12:57:34 +08:00
JzoNg f0e4885926 tooltip of endpoints 2024-11-17 10:54:40 +08:00
Yeuoly 2698b1c222 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-15 19:54:56 +08:00
Yeuoly 2cb640de15 refactor: load tools cache 2024-11-15 19:53:50 +08:00
Yeuoly 59b76900d7 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-15 18:39:40 +08:00
Yeuoly fb4ee813c7 fix: agent 2024-11-15 18:37:33 +08:00
Joel 1dc2d7f4a2 chore: fix jump url 2024-11-15 16:49:12 +08:00
StyleZhang cc28dafede Merge branch 'feat/plugins' into dev/plugin-deploy 2024-11-15 16:46:46 +08:00
StyleZhang 9193bc3143 fix: marketplace link 2024-11-15 16:46:23 +08:00
Joel 3b032f086d fix: market icon not show 2024-11-15 16:37:51 +08:00
StyleZhang 5be781e007 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-11-15 16:33:17 +08:00
StyleZhang 746838e276 fix: marketplace link 2024-11-15 16:32:49 +08:00
Yi 5ea306850e fix: copy tooltip shows in wrong place 2024-11-15 16:23:11 +08:00
Joel 7fe16a9f9d merge 2024-11-15 16:13:40 +08:00
Yi a6be3fdcd0 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-15 16:09:21 +08:00
Yi a7a5c6f4cb fix: update the upgrade button text content in the header 2024-11-15 16:09:04 +08:00
twwu f53b658964 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-15 16:07:41 +08:00
twwu 70bf321fd7 fix: add plugin type to card payload and integrate categories hook 2024-11-15 16:07:34 +08:00
Yeuoly 6da877c6a6 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-15 15:56:45 +08:00
Yeuoly 6300e506fb fix: rag 2024-11-15 15:54:14 +08:00
StyleZhang 35eafd239d fix: plugin task 2024-11-15 15:50:14 +08:00
StyleZhang 3f2baf0131 fix: plugin task 2024-11-15 15:46:29 +08:00
Yeuoly a0543ab8fb Merge branch 'main' into fix/chore-fix 2024-11-15 15:43:32 +08:00
StyleZhang a5a6969db3 fix 2024-11-15 15:36:32 +08:00
StyleZhang c176494405 fix: search box style 2024-11-15 15:26:29 +08:00
Joel 1e81476e3a chore: fix lockfile 2024-11-15 15:24:08 +08:00
Joel 6fbff78b9c merge 2024-11-15 15:16:53 +08:00
Joel 0738c2ef54 fix: can not get url 2024-11-15 15:03:18 +08:00
StyleZhang 984e4564f8 fix: dsl check plugin 2024-11-15 14:54:17 +08:00
StyleZhang bc927868f4 fix: plugin task 2024-11-15 14:54:17 +08:00
Joel a0758dc2fc feat: finish github install 2024-11-15 14:40:04 +08:00
Joel 6b759795d5 feat: can install github 2024-11-15 13:09:29 +08:00
Joel bba80f465b just add 2024-11-15 13:09:28 +08:00
Joel ebaa94be15 mrege 2024-11-15 12:11:00 +08:00
Joel 6699441e53 just add 2024-11-15 12:07:20 +08:00
Yi 735e47f5e5 chore: update the styling in the "members setting" 2024-11-15 11:29:48 +08:00
twwu d354c69493 chore: update translations to include 'Marketplace' terminology in Chinese localization 2024-11-15 11:05:20 +08:00
JzoNg 8f14881aff app parameters 2024-11-15 10:43:21 +08:00
JzoNg e53c4fc0ad empty inputs form of app selector 2024-11-15 10:43:21 +08:00
JzoNg f9f2e68bd8 app selector in form 2024-11-15 10:43:21 +08:00
JzoNg 7b4d67d72f app list filter 2024-11-15 10:43:21 +08:00
JzoNg 7446244147 app picker 2024-11-15 10:43:21 +08:00
JzoNg c723bd2c96 app selector trigger 2024-11-15 10:43:21 +08:00
Joel 73ce8a17a5 feat: add loading 2024-11-15 10:39:57 +08:00
Yeuoly 1812af6cfe Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-15 00:47:46 +08:00
Yeuoly 634cb6233e feat: sypport batch fetch plugin installations 2024-11-15 00:47:25 +08:00
Yeuoly 94a8547217 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-14 22:59:18 +08:00
Yeuoly db68ae4a73 feat: support upload bundle 2024-11-14 22:58:57 +08:00
Yeuoly 5bd7598a37 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-14 18:34:32 +08:00
Yeuoly d25e79e794 feat: support uploading images through plugin 2024-11-14 18:32:51 +08:00
Joel 6f5e010db5 chore: handle uploaded selected 2024-11-14 18:31:22 +08:00
Yi 495d86fd96 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-14 18:28:18 +08:00
Yi 42ba4e4f0e chore: update the plugins tab button 2024-11-14 18:26:16 +08:00
StyleZhang 6af51701de fix: card link 2024-11-14 18:18:10 +08:00
Joel 76104d811c feat: can show install plugins 2024-11-14 16:54:36 +08:00
StyleZhang 1877433f20 fix: marketplace 2024-11-14 16:37:53 +08:00
Yi a403fb565d chore: update the plan tags 2024-11-14 16:21:28 +08:00
twwu f58b88f319 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-14 15:47:27 +08:00
twwu cd2860deb4 feat: add i18n support for plugin installation and empty states 2024-11-14 15:47:22 +08:00
AkaraChen 070968a048 style: add lint rule for tailwind 2024-11-14 15:39:21 +08:00
StyleZhang ceb18d160f fix: marketplace i18n 2024-11-14 14:56:15 +08:00
StyleZhang 6a63a03cb2 feat: tool list use query 2024-11-14 14:48:13 +08:00
twwu a0a62db6ad refactor: Split linear-gradient and color 2024-11-14 14:36:30 +08:00
StyleZhang 253abaf1a3 fix: marketplace empty page 2024-11-14 14:27:34 +08:00
AkaraChen 44cc6157f1 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-14 11:35:53 +08:00
Yi 028fc00be6 chore: update i18n & setting window 2024-11-14 11:19:39 +08:00
AkaraChen 1aed0fe5d6 chore: use mitt hook 2024-11-14 11:04:41 +08:00
JzoNg 300cd675c6 update tool list after tool selector 2024-11-14 00:04:06 +08:00
JzoNg ff1d42bd66 add tool selector in endpoint modal 2024-11-14 00:02:04 +08:00
JzoNg 194a99220b authorization of tool selector 2024-11-14 00:02:04 +08:00
JzoNg 926f85ce4f tool selector trigger 2024-11-14 00:02:04 +08:00
Yi 6c6e1e90cd Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-13 18:41:27 +08:00
twwu 2fbc0c2261 revert: revert category label handling in plugin card component 2024-11-13 18:40:23 +08:00
Yi bac1e99557 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-13 18:40:20 +08:00
Yi 93e3077f77 chore: update the esc button and the upgrade button 2024-11-13 18:40:11 +08:00
twwu fa6858090b refactor: remove version prop from plugin item components and update version comparison logic 2024-11-13 18:34:04 +08:00
twwu 61eb655823 feat: update plugin category labels and improve internationalization support 2024-11-13 18:30:38 +08:00
twwu 6298332950 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-13 16:55:49 +08:00
twwu a1719c49b7 feat: add internationalization support for plugin categories and update translations 2024-11-13 16:55:43 +08:00
Yi b10a1cd325 chore: update the theme selector setting in globals.css 2024-11-13 16:43:00 +08:00
StyleZhang aa88028564 fix: marketplace list 2024-11-13 16:28:38 +08:00
Joel 3e314843db chore: add missing file 2024-11-13 16:23:33 +08:00
Joel 0d607a8c90 feat: add update workflow to update use query 2024-11-13 16:23:31 +08:00
StyleZhang 577a948f42 feat: dsl check plugin 2024-11-13 15:48:25 +08:00
Yeuoly 1c411143e5 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-13 15:19:32 +08:00
Yeuoly 183b943803 feat: support check dependencies through url 2024-11-13 15:19:20 +08:00
Joel edbfe27eb1 chore: add invalid all built in tools 2024-11-13 15:17:22 +08:00
Joel 5c98d80fdf chore: more filter text content 2024-11-13 15:12:58 +08:00
Joel 89b470d0d5 fix: toggle tool 2024-11-13 15:04:23 +08:00
Joel 19dc983d30 feat: support toggle set tool when the texts changes 2024-11-13 14:54:37 +08:00
twwu e842a46fe2 fix: resolve issue with dark mode 2024-11-13 14:43:37 +08:00
Yeuoly 612eba2765 tests: for CD 2024-11-13 14:30:55 +08:00
Yeuoly 4fdaf57897 refactor 2024-11-13 14:28:40 +08:00
Yeuoly 479928f428 refactor cd 2024-11-13 14:23:02 +08:00
Yeuoly a53ea578b9 tests: cd 2024-11-13 14:11:46 +08:00
Joel 1573f6f6aa feat: add tag and q filter 2024-11-13 14:08:16 +08:00
snakeandGitHub 3c6babdf35 cd for plugin env 2024-11-13 13:58:58 +08:00
AkaraChen f74dc032f9 fix: new workflow init draft failed 2024-11-13 13:51:55 +08:00
snakeandGitHub bc614cb507 cd for plugin env 2024-11-13 13:38:12 +08:00
AkaraChen 910d5df513 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-13 13:33:47 +08:00
snakeandGitHub 92c2fa0a88 deploy script add cat action 2024-11-13 13:28:46 +08:00
twwu fa01360498 fix: Fix theme initialization issue 2024-11-13 13:11:47 +08:00
AkaraChen 1fe5be532d fix: new workflow init draft failed 2024-11-13 12:59:52 +08:00
Joel d67eb907dd fix: show index letter problem 2024-11-13 11:56:33 +08:00
Joel 83dae7e5bc fix: can not select action in workflow and tools 2024-11-13 11:38:44 +08:00
StyleZhang c6d1b7869d fix: plugin task 2024-11-13 11:33:58 +08:00
snakeandGitHub 32b8efcc73 cd for plugin env 2024-11-13 11:28:31 +08:00
snakeandGitHub 3aa679b061 cd for plugin env 2024-11-13 11:11:30 +08:00
snakeandGitHub 07def4587c cd for plugin env 2024-11-13 11:01:37 +08:00
snakeandGitHub 830bf4dc3c print context var 2024-11-13 10:51:40 +08:00
snakeandGitHub e1c2929219 print context var 2024-11-13 10:48:02 +08:00
snakeandGitHub 3976c7fee8 print context var 2024-11-13 10:44:33 +08:00
snakeandGitHub 11fd02ae99 print context var 2024-11-13 10:42:01 +08:00
Yi 601d267b7a Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-13 10:39:07 +08:00
Yi 327940a120 chore: update the update plugin from GitHub 2024-11-13 10:38:56 +08:00
snakeandGitHub d89ab877b7 print context var 2024-11-13 10:32:43 +08:00
snakeandGitHub e83d2da661 print context var 2024-11-13 10:31:45 +08:00
snakeandGitHub f3986c5600 print context var 2024-11-13 10:30:49 +08:00
snakeandGitHub a31693c273 print context var 2024-11-13 10:30:07 +08:00
snakeandGitHub 0e541da25e print context var 2024-11-13 10:22:05 +08:00
snakeandGitHub 64ffe96480 print context var 2024-11-13 10:21:11 +08:00
Yeuoly 8ed2695286 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-12 21:43:44 +08:00
Yeuoly 5828abcd62 fix: uses to check if the tools are already loaded 2024-11-12 21:43:19 +08:00
Yeuoly a42b081e32 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-12 20:48:51 +08:00
Yeuoly 56bd0dedfe fix: incorrect paths to upgrade plugins 2024-11-12 20:48:28 +08:00
Yeuoly beea9d01f3 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-12 19:57:32 +08:00
Yeuoly f6136427a4 feat: export dsl with dependencies 2024-11-12 19:50:56 +08:00
Yeuoly 21fd58caf9 Merge branch 'fix/chore-fix' of github.com:langgenius/dify into fix/chore-fix 2024-11-12 18:53:45 +08:00
snakeandGitHub 641153eed8 print context var 2024-11-12 18:47:24 +08:00
snakeandGitHub 370736cad9 print context var 2024-11-12 18:38:46 +08:00
snakeandGitHub 153f3b77ec print context var 2024-11-12 18:29:48 +08:00
StyleZhang 582c7ce348 fix: plugin task 2024-11-12 18:28:34 +08:00
snakeandGitHub 88611fe1aa print context var 2024-11-12 18:23:02 +08:00
snakeandGitHub ede82299e1 print context var 2024-11-12 18:14:31 +08:00
snakeandGitHub f031eeb473 print context var 2024-11-12 17:58:34 +08:00
StyleZhang 13d3f67746 feat: plugin task use query 2024-11-12 17:58:32 +08:00
snakeandGitHub 61096d7f7a print context var 2024-11-12 17:54:54 +08:00
snakeandGitHub 5b703d1792 print context var 2024-11-12 17:51:00 +08:00
Joel 9c6aafd415 feat: install bundle ui 2024-11-12 17:33:10 +08:00
snakeandGitHub 1af087abc1 print context var 2024-11-12 17:19:45 +08:00
nite-knite 3716ea46b5 chore: bump elliptic from 6.5.7 to 6.6.0 2024-11-12 17:19:02 +08:00
snakeandGitHub d3d84217a7 print context var 2024-11-12 17:16:49 +08:00
snakeandGitHub 51e230309b revert deploy-dev.yml 2024-11-12 17:14:31 +08:00
JzoNg 3c89b8a698 confirm model selector schema in agent and workflow 2024-11-12 16:57:22 +08:00
JzoNg b188800f16 model selector in endpoint modal 2024-11-12 16:57:22 +08:00
JzoNg 75a037bc2a update style of model & parameter selector 2024-11-12 16:57:22 +08:00
JzoNg 5efcdd6fa7 model parameters 2024-11-12 16:57:22 +08:00
JzoNg 06c4627abb tool selecting in configure 2024-11-12 16:57:22 +08:00
JzoNg f5267d317e fix quota of model provider 2024-11-12 16:57:22 +08:00
twwu 2573950f88 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-12 16:48:28 +08:00
twwu 2ba38c6c45 feat: add marketplace-divider-bg color variable for dark and light themes 2024-11-12 16:48:24 +08:00
Joel 07edda8a85 feat: add new marketplace env 2024-11-12 15:56:03 +08:00
snakeandGitHub 81116a679d Update deploy-dev.yml for print context var 2024-11-12 15:55:19 +08:00
twwu 7791d290c7 refactor: update AudioPlayer styles with CSS variables and improve VideoGallery rendering 2024-11-12 15:49:00 +08:00
Joel 8203b23df2 feat: install bundle struct 2024-11-12 15:48:00 +08:00
AkaraChen e175ad9963 fix: sse post no token 2024-11-12 14:41:09 +08:00
Joel d4c9c76454 chore: mask the debug key 2024-11-12 14:31:15 +08:00
AkaraChen a059660ed8 fix: sse post no token 2024-11-12 14:24:18 +08:00
Yi 20357beda4 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-12 13:32:26 +08:00
Joel 7e39565fd2 feat: handle on update show update modal 2024-11-12 11:48:55 +08:00
Yeuoly a37e41de99 fix: add pnpm lock 2024-11-11 21:04:15 +08:00
Yeuoly 0a9dd367f6 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-11 21:01:23 +08:00
Yeuoly 9a69d03fbe feat: add icon and labels to plugin install task 2024-11-11 20:59:31 +08:00
takatost 1d2118fc5d fix: hosted moderation 2024-11-11 20:31:11 +08:00
takatost bc0724b499 chore: fix typo 2024-11-11 19:50:39 +08:00
StyleZhang 27f794e197 feat: plugin task 2024-11-11 18:17:58 +08:00
Yi a8e8e36756 chore: update the upgrade button 2024-11-11 18:00:44 +08:00
Yi dbc10425c8 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-11 17:21:37 +08:00
Yi 810443c511 chore: update the upgrade button and add premium badge component 2024-11-11 17:21:25 +08:00
Joel f47b5ce63a chore: install plugin by local use use query 2024-11-11 14:58:17 +08:00
Yeuoly e3723f65f8 fix: temp fix for seucrity issues 2024-11-11 14:10:57 +08:00
Yeuoly ba2d340109 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-11 14:06:39 +08:00
Yeuoly 5cdbfe2f41 Merge branch 'main' into fix/chore-fix 2024-11-11 14:00:53 +08:00
Yeuoly 2a87f61515 fix: avoid empty plugin entity 2024-11-11 13:32:03 +08:00
Yeuoly 5fd82084f9 fix: avoid empty plugin entity 2024-11-11 13:30:11 +08:00
StyleZhang 822c18cb76 fix: credentials: 2024-11-11 12:27:58 +08:00
StyleZhang 66b08e653e fix: credentials: 2024-11-11 12:27:13 +08:00
JzoNg 5e81150b22 useQuery for endpoints 2024-11-09 14:44:48 +08:00
JzoNg 1e62768eed useQuery in action list 2024-11-09 12:51:10 +08:00
JzoNg 59a9235041 useQuery for model list 2024-11-09 12:12:10 +08:00
takatost 0b2b6a3ef3 Merge branch 'refs/heads/fix/chore-fix' into dev/plugin-deploy 2024-11-08 23:11:02 +08:00
takatost f0637ba332 fix: create basic app causing internal error when default model is not exist 2024-11-08 23:09:52 +08:00
JzoNg f85ff9ef78 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-11-08 21:34:59 +08:00
JzoNg f2bf2e4470 fix style of provider added card 2024-11-08 21:32:46 +08:00
takatost 48fac5187a Merge branch 'refs/heads/fix/chore-fix' into dev/plugin-deploy 2024-11-08 19:24:44 +08:00
takatost 115c9486c3 fix hosted issues 2024-11-08 19:23:49 +08:00
Joel c77b38b97d chore: install from marketplace 2024-11-08 18:29:54 +08:00
StyleZhang 33349191e9 marketplace usemutation 2024-11-08 18:21:58 +08:00
Yeuoly 1a5c2d1d58 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-08 17:27:35 +08:00
Yeuoly 8b5231b7ee fix: invalid key of marketplace response 2024-11-08 17:27:16 +08:00
AkaraChen d4f7ebfd2e feat: refactor http client 2024-11-08 17:21:55 +08:00
Yeuoly c34970c631 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-08 17:21:06 +08:00
Yeuoly 38cae29757 fix: wrap marketplace apis with try catch 2024-11-08 17:20:54 +08:00
JzoNg ebdf72fffc check update 2024-11-08 17:01:49 +08:00
JzoNg 1f1c61541e install from settings 2024-11-08 16:33:00 +08:00
JzoNg f70c23dd7a endpoints api 2024-11-08 16:19:00 +08:00
JzoNg f498686c3a model list style fix 2024-11-08 16:19:00 +08:00
StyleZhang d13169934d fix: marketplace i18n 2024-11-08 16:14:29 +08:00
Joel 324437b3f1 feat: mutation permersions 2024-11-08 16:12:04 +08:00
twwu c6a6c53084 chore: update theme var define 2024-11-08 15:26:59 +08:00
Joel edc2fe050a chore: debug info use query 2024-11-08 15:10:06 +08:00
Joel 6fcebf3ecd chore: remove log 2024-11-08 14:26:52 +08:00
Joel b754bf80ae fix: custom tools not show 2024-11-08 14:24:28 +08:00
Joel 5d7c527702 merge feat/plugins 2024-11-08 13:57:34 +08:00
Joel a9de7f24a2 merge main 2024-11-08 13:55:39 +08:00
Yeuoly 14a723a2a4 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-08 13:48:23 +08:00
Yeuoly 7a2b2a04c9 Merge branch 'main' into fix/chore-fix 2024-11-08 13:47:24 +08:00
twwu 6759c6d5e6 Revert "feat: add gray label color variables for dark and light themes"
This reverts commit a75cef2c3b.
2024-11-08 13:42:38 +08:00
Yeuoly 61cf6e1c7b Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-08 13:39:45 +08:00
JzoNg 920d6d6882 fix credentials of action list 2024-11-08 12:32:02 +08:00
JzoNg 2511968cb4 fix action list 2024-11-08 12:32:02 +08:00
JzoNg f684e1c12e provider compatible in logs 2024-11-08 12:32:02 +08:00
JzoNg be75a1e432 provider compatible in moderation 2024-11-08 12:32:02 +08:00
JzoNg 5a679ed396 provider compatible in model_config 2024-11-08 12:32:02 +08:00
JzoNg 0cfd676fd6 provider compatible 2024-11-08 12:32:02 +08:00
twwu d997499ecf Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-08 11:33:42 +08:00
twwu 4d3ffbb6f0 fix: update repository URL format in plugin action component 2024-11-08 11:33:35 +08:00
twwu a710858d09 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-08 11:32:34 +08:00
twwu a75cef2c3b feat: add gray label color variables for dark and light themes 2024-11-08 11:31:48 +08:00
Yi 392db19ea2 chore: update the update plugin steps 2024-11-08 11:08:40 +08:00
Yi 7cb6039833 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-07 18:22:08 +08:00
Yi e041a9e418 chore: upgrade button styling 2024-11-07 18:21:32 +08:00
Joel 281c6dc337 merge 2024-11-07 17:44:54 +08:00
-LAN-andJoel 7d7ade26ce fix(remote-files): fallback to get when remote server not support head method (#10370) 2024-11-07 17:39:52 +08:00
-LAN-andJoel 6aa2af215b refactor(iteration): introduce specific exceptions for iteration errors (#10366) 2024-11-07 17:39:52 +08:00
-LAN-andJoel 598d307afd refactor(knowledge-retrieval): improve error handling with custom exceptions (#10385) 2024-11-07 17:39:52 +08:00
-LAN-andJoel 39fdcfd7e9 refactor(tool-node): introduce specific exceptions for tool node errors (#10357) 2024-11-07 17:39:51 +08:00
-LAN-andJoel 47f638e5aa refactor(question_classifier): improve error handling with custom exceptions (#10365) 2024-11-07 17:39:51 +08:00
03b57d1f0a fixed: web api remote urls error (#10383)
Co-authored-by: hobo.l <hobo.l@binance.com>
2024-11-07 17:39:51 +08:00
powerfoolandJoel 99c84c423e Adjusted docker manifests and environment variables for OceanBase vector database (#10395) 2024-11-07 17:39:51 +08:00
omrandJoel cc2cc56f25 fix typo: mMaximum -> Maximum (#10389) 2024-11-07 17:39:50 +08:00
非法操作andJoel 393885ee16 fix: remove duplicated category “recommended” (#10375) 2024-11-07 17:39:50 +08:00
MatsudaandJoel 9143d460fa fix(model_runtime): remove vision from features for Claude 3.5 Haiku (#10360) 2024-11-07 17:39:49 +08:00
InfinitnetandJoel c0ff0cf7cf fix: remove unsupported vision in OpenRouter Haiku 3.5 (#10364) 2024-11-07 17:39:49 +08:00
Bowen LiangandJoel 9c90d98027 chore(ci): bring back poetry cache to speed up CI jobs (#10347) 2024-11-07 17:39:48 +08:00
Bowen LiangandJoel 0d74466f45 chore: lazy import sagemaker (#10342) 2024-11-07 17:39:48 +08:00
comfutureandJoel d2e293b9be chore: update translation for 'account' from '계좌' to '계정' (#10350) 2024-11-07 17:39:48 +08:00
-LAN-andJoel 8fae321b6a chore(ci): separate vector store tests into new workflow (#10354) 2024-11-07 17:39:47 +08:00
-LAN-andJoel a2b42c9431 fix(api): remove fixed source attribute from FileApi (#10353) 2024-11-07 17:39:47 +08:00
0a4b256b5a feat: support png, gif, webp (#7947)
Co-authored-by: xuanson9699 <84961581+xuanson9699@users.noreply.github.com>
2024-11-07 17:39:47 +08:00
Chenhe GuandJoel 9f7124a79d Update README.md (#10332) 2024-11-07 17:39:46 +08:00
方程andJoel 7a217534d1 Gitee AI tools (#10314) 2024-11-07 17:39:46 +08:00
Summer-GuandJoel a9ed0f0b42 feat: The SSRF request timeout configuration item is added (#10292) 2024-11-07 17:39:46 +08:00
InfinitnetandJoel 545d2b2622 feat: add support for anthropic/claude-3-5-haiku through OpenRouter (#10331) 2024-11-07 17:39:45 +08:00
BenjaminandJoel f114da4e81 feat(vannaai): add base_url configuration (#10294) 2024-11-07 17:39:45 +08:00
-LAN-andJoel f4e3e3fc19 docs: remove the TOC part (#10324) 2024-11-07 17:39:45 +08:00
非法操作andJoel 1277941821 fix: special prompt not work for comfyUI tool (#10307) 2024-11-07 17:39:45 +08:00
-LAN-andJoel f500e6cf5b chore: update version to 0.11.0 across all relevant files (#10278) 2024-11-07 17:39:44 +08:00
NoviceandJoel a3b71830d0 fix: iteration none output error (#10295) 2024-11-07 17:39:44 +08:00
-LAN-andJoel 13b7e18a50 fix(http_request): improve parameter initialization and reorganize tests (#10297) 2024-11-07 17:39:44 +08:00
MatsudaandJoel 5f4bb12a1a fix typo: writeOpner to writeOpener (#10290) 2024-11-07 17:39:43 +08:00
pinsilyandJoel 781e8e1a4a fix: handle KeyError when accessing rules in CleanProcessor.clean (#10258) 2024-11-07 17:39:43 +08:00
euxandJoel c721617e19 fix: borken faq url in CONTRIBUTING.md (#10275) 2024-11-07 17:39:43 +08:00
非法操作andJoel 6b51e81de1 feat: add xAI model provider (#10272) 2024-11-07 17:39:43 +08:00
MatsudaandJoel 736719745c feat(model_runtime): add new model 'claude-3-5-haiku-20241022' (#10285) 2024-11-07 17:39:43 +08:00
MatsudaandJoel e0e4a6f819 fix(model_runtime): fix wrong max_tokens for Claude 3.5 Haiku on Amazon Bedrock (#10286) 2024-11-07 17:39:42 +08:00
-LAN-andJoel 6ab6b9cc40 feat(model): add validation for custom disclaimer length (#10287) 2024-11-07 17:39:42 +08:00
-LAN-andJoel 52eb18937e fix(node): correct file property name in function switch (#10284) 2024-11-07 17:39:42 +08:00
NFishandJoel aab1ab692a refactor the logic of refreshing access_token (#10068) 2024-11-07 17:39:40 +08:00
3e7f38d904 chore: translate i18n files (#10273)
Co-authored-by: laipz8200 <16485841+laipz8200@users.noreply.github.com>
Co-authored-by: crazywoola <100913391+crazywoola@users.noreply.github.com>
2024-11-07 17:39:15 +08:00
BenjaminandJoel 94c5e36334 Updates: Add mplfonts library for customizing matplotlib fonts and Va… (#9903) 2024-11-07 17:39:14 +08:00
NoviceandJoel baaa3ae02c feat: Iteration node support parallel mode (#9493) 2024-11-07 17:39:09 +08:00
GeorgeCaoJandJoel 623b27583b fix(workflow): handle else condition branch addition error in if-else node (#10257) 2024-11-07 17:38:39 +08:00
-LAN-andJoel 93e9aeb4e9 feat(document_extractor): support tool file in document extractor (#10217) 2024-11-07 17:38:39 +08:00
MatsudaandJoel 391ad7734e feat: support Claude 3.5 Haiku on Amazon Bedrock (#10265) 2024-11-07 17:38:38 +08:00
-LAN-andJoel c5422af400 refactor(parameter_extractor): implement custom error classes (#10260) 2024-11-07 17:38:37 +08:00
65a04ee0be fix: buitin tool aippt (#10234)
Co-authored-by: jinqi.guo <jinqi.guo@ubtrobot.com>
2024-11-07 17:38:37 +08:00
-LAN-andJoel 84c35aef6c fix(validation): allow to use 0 in the inputs form (#10255) 2024-11-07 17:38:37 +08:00
-LAN-andJoel c2b4845719 chore(Dockerfile): upgrade zlib arm64 (#10244) 2024-11-07 17:38:37 +08:00
方程andJoel cd0f10567f Using a dedicated interface to obtain the token credential for the gitee.ai provider (#10243) 2024-11-07 17:38:36 +08:00
454b755c6b feat(workflow): add configurable workflow file upload limit (#10176)
Co-authored-by: JzoNg <jzongcode@gmail.com>
2024-11-07 17:38:35 +08:00
shisaru292andJoel 352c1fc370 fix: missing working directory parameter in script (#10226) 2024-11-07 17:38:35 +08:00
-LAN-andJoel 181eb6038f refactor(list_operator): replace ValueError with InvalidKeyError (#10222) 2024-11-07 17:38:34 +08:00
-LAN-andJoel c32cbeb29a refactor(workflow): introduce specific error handling for LLM nodes (#10221) 2024-11-07 17:38:34 +08:00
-LAN-andJoel 62f8c875c8 refactor(http_request): add custom exception handling for HTTP request nodes (#10219) 2024-11-07 17:38:33 +08:00
-LAN-andJoel baed53bbfa refactor(workflow): introduce specific exceptions for code validation (#10218) 2024-11-07 17:38:32 +08:00
-LAN-andJoel 565a0d992a chore(llm_node): remove unnecessary type ignore for context assignment (#10216) 2024-11-07 17:38:32 +08:00
JyongandJoel e90a06a7b7 fix the ssrf of docx file extractor external images (#10237) 2024-11-07 17:38:31 +08:00
Hanqing ZhaoandJoel 5a0b22dbd4 Modify translation (#10213) 2024-11-07 17:38:30 +08:00
31445c3782 Add Lindorm as a VDB choice (#10202)
Co-authored-by: jiangzhijie <jiangzhijie.jzj@alibaba-inc.com>
2024-11-07 17:38:30 +08:00
crazywoolaandJoel 8e6f5f4bb0 Fix/10199 application error a client side exception has occurred see the browser console for more information (#10211) 2024-11-07 17:38:29 +08:00
-LAN-andJoel e259b360c2 refactor(validation): improve input validation logic (#10175) 2024-11-07 17:38:29 +08:00
-LAN-andJoel 762dec2dc4 chore(list_operator): refine exception handling for error specificity (#10206) 2024-11-07 17:38:28 +08:00
-LAN-andJoel ada7f5c30f fix(document_extractor): update base exception class (#10208) 2024-11-07 17:38:28 +08:00
Kota-YamaguchiandJoel 6b965eaea3 Feat : add LLM model indicator in prompt generator (#10187) 2024-11-07 17:38:27 +08:00
Xiao LeyandJoel ea67bc1166 chore: enable vision support for models in OpenRouter that should have supported vision (#10191) 2024-11-07 17:38:26 +08:00
Kota-YamaguchiandJoel 01e8f6066a chore : code generator preview hint (#10188) 2024-11-07 17:38:26 +08:00
zxhlyhandJoel 39effd350e fix: webapp upload file (#10195) 2024-11-07 17:38:25 +08:00
-LAN-andJoel 00bfb35759 fix(api): replace current_user with end_user in file upload (#10194) 2024-11-07 17:38:25 +08:00
-LAN-andJoel 101d9798f0 feat(document_extractor): integrate unstructured API for PPTX extraction (#10180) 2024-11-07 17:38:24 +08:00
-LAN-andJoel ba48754be6 fix(tools): suppress RuntimeWarnings in podcast audio generator (#10182) 2024-11-07 17:38:24 +08:00
Cling_o3andJoel d963df32b9 [fix] fix the bug that modify document name not effective (#10154) 2024-11-07 17:38:23 +08:00
-LAN-andJoel 67ce763377 fix(workflow model): ensure consistent timestamp updating (#10172) 2024-11-07 17:38:23 +08:00
a32c0ef43c fix: Cannot find declaration to go to CLEAN_DAY_SETTING (#10157)
Co-authored-by: 刘江波 <liujiangbo1@xiaomi.com>
2024-11-07 17:38:22 +08:00
Lawrence LiandJoel 6e03c10285 feat: add gpustack model provider (#10158) 2024-11-07 17:38:21 +08:00
-LAN-andJoel 8f14c422a7 refactor(tools): Avoid warnings. (#10161) 2024-11-07 17:38:20 +08:00
-LAN-andJoel 07787366cd refactor(migration/model): update column types for workflow schema (#10160) 2024-11-07 17:38:20 +08:00
-LAN-andJoel 8f2d3b6743 Feat/add-remote-file-upload-api (#9906) 2024-11-07 17:38:19 +08:00
zxhlyhandJoel e7bc863f26 fix: upload remote image preview (#9952) 2024-11-07 17:38:19 +08:00
JyongandJoel 1d411e195a clean un-allowed special charters when doing indexing estimate (#10153) 2024-11-07 17:38:19 +08:00
-LAN-andJoel 2a7ae6b0df refactor(service): handle unsupported DSL version with warning (#10151) 2024-11-07 17:38:18 +08:00
8f8a3f4318 Add VESSL AI OpenAI API-compatible model provider and LLM model (#9474)
Co-authored-by: moon <moon@vessl.ai>
2024-11-07 17:38:18 +08:00
Kota-YamaguchiandJoel 4b89dba3a5 feat: synchronize input/output variables in the panel with generated code by the code generator (#10150) 2024-11-07 17:38:18 +08:00
Zixuan ChengandJoel 19c0d1fbf8 Refined README for better reading experience. (#10143) 2024-11-07 17:38:17 +08:00
94cd4912e1 add llm: ernie-4.0-turbo-128k of wenxin (#10135)
Co-authored-by: Pigeon姚宏锋 <pigeon.yhf@galaxyoversea.com>
2024-11-07 17:38:17 +08:00
Shili CaoandJoel 602f75bb30 fix: avoid unexpected error when create knowledge base with baidu vector database and wenxin embedding model (#10130) 2024-11-07 17:38:15 +08:00
c2810de952 fix: bar chart issue with duplicate x-axis labels being incorrectly ignored (#10134)
Co-authored-by: liusurong.lsr <liusurong.lsr@alibaba-inc.com>
2024-11-07 17:38:14 +08:00
JyongandJoel 1b645c1cc9 fix issue: query is none when doing retrieval (#10129) 2024-11-07 17:38:14 +08:00
ae3482e0b4 Fix/rerank validation issue (#10131)
Co-authored-by: Yi <yxiaoisme@gmail.com>
2024-11-07 17:38:14 +08:00
76c265f781 Feat/update knowledge api url (#10102)
Co-authored-by: nite-knite <nkCoding@gmail.com>
2024-11-07 17:38:12 +08:00
omrandJoel b1946c60d8 fix: optimize unique document filtering with set (#10082) 2024-11-07 17:38:12 +08:00
-LAN-andJoel c1c13cf828 fix(Dockerfile): conditionally install zlib1g based on architecture (#10118) 2024-11-07 17:38:11 +08:00
Hash BrownandJoel e4a48e28e5 fix: log detail panel not showing any message when total count greate… (#10119) 2024-11-07 17:38:11 +08:00
JyongandJoel 67efcbd6bb fix issue: update document segment setting failed (#10107) 2024-11-07 17:38:11 +08:00
Nam VuandJoel 7466061e5a fix: Version '1:1.3.dfsg+really1.3.1-1' for 'zlib1g' was not found (#10096) 2024-11-07 17:38:10 +08:00
-LAN-andJoel b7534b764d feat(app_dsl_service): enhance error handling and DSL version management (#10108) 2024-11-07 17:38:09 +08:00
非法操作andJoel eb335ed464 chore: save uploaded file extension as lower case (#10111) 2024-11-07 17:38:09 +08:00
-LAN-andJoel 4d9e7c1884 refactor(version): simplify version comparison logic (#10109) 2024-11-07 17:38:09 +08:00
8f7cac6bde fix: view logs in prompt, no response when clicked (#10093)
Co-authored-by: zhanganguo <zhanganguo@lixiang.com>
2024-11-07 17:38:08 +08:00
非法操作andJoel d4608f0571 chore: remove an unnecessary link (#10088) 2024-11-07 17:38:08 +08:00
非法操作andJoel 9f27b5bb12 feat: enhance comfyui workflow (#10085) 2024-11-07 17:38:07 +08:00
AkaraChenandJoel fb9c54e35f build: update docker login action (#10050) 2024-11-07 17:38:07 +08:00
Kota-YamaguchiandJoel dea45682bc chore: update type definition to resolve lint error in Base usage at text-editor.tsx (#10083) 2024-11-07 17:38:06 +08:00
Bowen LiangandJoel a0abd5d077 improve: significantly speed up the server launching time by async preloading tool providers (#9146) 2024-11-07 17:38:05 +08:00
Charlie.WeiandJoel 924dbc128d fix azure chatgpt o1 parameter error (#10067) 2024-11-07 17:38:05 +08:00
crazywoolaandJoel b76aa11919 Revert "chore: improve validation and handler of logging timezone with TimezoneName" (#10077) 2024-11-07 17:38:05 +08:00
sacryuandJoel 7971efd23e fix the typos in the hit testing template (#10072) 2024-11-07 17:38:04 +08:00
JasonVVandJoel b8c2e5359b Fixed the issue where recall the knowledge base in the iteration of the workflow and report errors when executing (#10060) 2024-11-07 17:38:04 +08:00
Hiroshi FujitaandJoel 952847ed29 chore: Set file size limits for video and audio uploads from docker env (#10063) 2024-11-07 17:38:03 +08:00
Fog3211andJoel 4e4a8a327b fix: prevent onChange during IME composition (#10059) 2024-11-07 17:38:03 +08:00
22mSqRiandJoel 8d1591e5d5 fix: fix poetry install command in devcontainer (#9507) 2024-11-07 17:38:03 +08:00
-LAN-andJoel 4b8896e034 fix(workflow): refine variable type checks in LLMNode (#10051) 2024-11-07 17:38:02 +08:00
非法操作andJoel c2d3464a17 chore: mount config file of sandbox (#8576) 2024-11-07 17:38:02 +08:00
zhuhaoandJoel 0886c6f224 fix: resolve the incorrect model name of hunyuan-standard-256k (#10052) 2024-11-07 17:38:01 +08:00
zhuhaoandJoel 1ee4c13758 chore: use dify_config.TIDB_SPEND_LIMIT instead of constant value (#10038) 2024-11-07 17:38:01 +08:00
郭伟伟andJoel c293aceec1 feat: /conversations api response add 'update_at' field,and update api docs add sort_by parameter (#10043) 2024-11-07 17:38:01 +08:00
zhuhaoandJoel 4d5752fc94 feat: add YAML type in document extractor node (#9997) 2024-11-07 17:38:00 +08:00
Xiao LeyandJoel c615ed57b9 add PROMPT_GENERATION_MAX_TOKENS and CODE_GENERATION_MAX_TOKENS in docker enviromment (#10040) 2024-11-07 17:38:00 +08:00
Yeuoly fe677cc5f9 Merge branch 'main' into fix/chore-fix 2024-11-07 17:06:29 +08:00
twwu 020d4baf92 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-07 16:52:26 +08:00
twwu 3f8a10613d refactor: remove unused fetchInstalledPluginList function and integrate useInstalledPluginList hook 2024-11-07 16:52:22 +08:00
AkaraChen 53fa13f007 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-07 16:44:46 +08:00
AkaraChen d00e1067bf fix: develop page docs style 2024-11-07 16:44:05 +08:00
Joel 2dd9c64d34 chore: use query 2024-11-07 16:42:44 +08:00
AkaraChen b7c40579b2 build: update tailwind 2024-11-07 16:41:35 +08:00
twwu c7f8a0fc7b Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-07 16:06:13 +08:00
twwu de24d9c145 fix: handle empty fetched releases and update locale usage in plugin item 2024-11-07 16:06:08 +08:00
AkaraChen 6357e1516e build: update react-hook-form 2024-11-07 15:47:07 +08:00
StyleZhang b83dc5ab99 fix: marketplace 2024-11-07 15:37:39 +08:00
Yi 65285965b6 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-07 15:31:42 +08:00
Yi 035c9eb147 fix: propagation from closing tag in filters 2024-11-07 15:31:11 +08:00
Joel 91b3aec292 feat: add use tools 2024-11-07 15:24:17 +08:00
AkaraChen d3a9747bbd build: update @floating-ui/react 2024-11-07 15:22:00 +08:00
StyleZhang 6a99fab92f fix: marketplace 2024-11-07 15:07:07 +08:00
Yi 2a590f6d2b Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-07 13:42:45 +08:00
Yi 117b0f20dd chore: update the plugin install dropdown styling 2024-11-07 13:42:34 +08:00
StyleZhang c445f747b7 fix: prompt editor 2024-11-07 12:11:26 +08:00
AkaraChen 8ed0963c6b Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-07 11:46:32 +08:00
Yi 6c47e0b5d1 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-07 11:37:21 +08:00
Yi e99e87269e chore: update the selectPackage component 2024-11-07 11:37:05 +08:00
AkaraChen 0a1319548a build: update react markdown
build: update react markdown

build: update react markdown
2024-11-07 11:34:55 +08:00
AkaraChen b1242ba1ac build: init @tanstack/react-query 2024-11-07 09:44:36 +08:00
twwu fde0e6c7f9 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-06 18:43:31 +08:00
twwu 92153328ea feat: add loading state for installed plugin list in context and update PluginsPanel to display loading indicator 2024-11-06 18:43:27 +08:00
Yeuoly 56f2464a4f Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-06 18:30:02 +08:00
Joel e66ba6ffdd chore: fill repo url 2024-11-06 18:13:15 +08:00
Yeuoly 28c9ec3f4f feat: support fetch tool provider info 2024-11-06 17:30:50 +08:00
Yeuoly 6baa98f166 feat: support app-selector, model-selector and tool-selector as parameters 2024-11-06 17:13:05 +08:00
twwu a7e320dc25 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-06 16:58:56 +08:00
twwu 5008d9f4a0 feat: add onSuccess callback to InstallFromGitHub and update plugin list on install actions 2024-11-06 16:58:52 +08:00
Yi 912f84777b Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-06 16:49:29 +08:00
Yi 4c0e4e490a chore: update the 'Update plugin from GitHub' 2024-11-06 16:49:16 +08:00
Joel 306843fe6a chore: plugin info 2024-11-06 16:42:32 +08:00
twwu b6a4af4041 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-06 16:18:25 +08:00
twwu cce39b85e9 feat: enhance plugin filtering with tags support 2024-11-06 16:18:18 +08:00
Joel 057d380119 feat: add install model plugin 2024-11-06 15:57:50 +08:00
Joel 4cf9ff6132 chore: remove log 2024-11-06 15:44:49 +08:00
Joel 4cfbcd9c79 feat: add install 2024-11-06 15:42:48 +08:00
StyleZhang fcde5b5c9e fix: detail 2024-11-06 15:37:12 +08:00
StyleZhang 21b3703bd8 fix: i18n 2024-11-06 15:23:38 +08:00
StyleZhang 9025e85ca5 locale 2024-11-06 15:00:37 +08:00
StyleZhang bc43e3a9fe card locale 2024-11-06 14:52:47 +08:00
StyleZhang 319a54aa2f i18n 2024-11-06 14:37:20 +08:00
StyleZhang 7c2ab21c9c i18n 2024-11-06 11:55:19 +08:00
twwu 0d08b6cf51 fix: enhance plugin installation and update handling 2024-11-06 09:50:05 +08:00
Yeuoly e9d69f020a feat: cast files into correct type while invoking 2024-11-05 20:30:13 +08:00
NoviceandYeuoly 3c89d45a2d fix: iteration none output error (#10295) 2024-11-05 20:30:13 +08:00
-LAN-andYeuoly baab81714e fix(http_request): improve parameter initialization and reorganize tests (#10297) 2024-11-05 20:30:13 +08:00
MatsudaandYeuoly 507bb3549a fix typo: writeOpner to writeOpener (#10290) 2024-11-05 20:30:13 +08:00
pinsilyandYeuoly 2d1e5fb4e0 fix: handle KeyError when accessing rules in CleanProcessor.clean (#10258) 2024-11-05 20:30:12 +08:00
euxandYeuoly b9198639e2 fix: borken faq url in CONTRIBUTING.md (#10275) 2024-11-05 20:30:12 +08:00
非法操作andYeuoly 43c7739b88 feat: add xAI model provider (#10272) 2024-11-05 20:30:12 +08:00
MatsudaandYeuoly f65d577f54 fix(model_runtime): fix wrong max_tokens for Claude 3.5 Haiku on Amazon Bedrock (#10286) 2024-11-05 20:30:00 +08:00
-LAN-andYeuoly b88145096f feat(model): add validation for custom disclaimer length (#10287) 2024-11-05 20:30:00 +08:00
-LAN-andYeuoly 33219e850a fix(node): correct file property name in function switch (#10284) 2024-11-05 20:30:00 +08:00
NFishandYeuoly 3040d538f7 refactor the logic of refreshing access_token (#10068) 2024-11-05 20:30:00 +08:00
4e1af81e11 chore: translate i18n files (#10273)
Co-authored-by: laipz8200 <16485841+laipz8200@users.noreply.github.com>
Co-authored-by: crazywoola <100913391+crazywoola@users.noreply.github.com>
2024-11-05 20:30:00 +08:00
BenjaminandYeuoly 56e19fd8f5 Updates: Add mplfonts library for customizing matplotlib fonts and Va… (#9903) 2024-11-05 20:30:00 +08:00
NoviceandYeuoly d330d31ee5 feat: Iteration node support parallel mode (#9493) 2024-11-05 20:29:59 +08:00
GeorgeCaoJandYeuoly 0858108423 fix(workflow): handle else condition branch addition error in if-else node (#10257) 2024-11-05 20:29:59 +08:00
-LAN-andYeuoly 2cd976846a feat(document_extractor): support tool file in document extractor (#10217) 2024-11-05 20:29:59 +08:00
MatsudaandYeuoly 5d2c88ef59 feat: support Claude 3.5 Haiku on Amazon Bedrock (#10265) 2024-11-05 20:29:59 +08:00
-LAN-andYeuoly fe3cde973e refactor(parameter_extractor): implement custom error classes (#10260) 2024-11-05 20:29:59 +08:00
-LAN-andYeuoly 794f495ef2 fix(validation): allow to use 0 in the inputs form (#10255) 2024-11-05 20:29:32 +08:00
-LAN-andYeuoly 0dda682033 chore(Dockerfile): upgrade zlib arm64 (#10244) 2024-11-05 20:29:31 +08:00
方程andYeuoly 01d8d10f1c Using a dedicated interface to obtain the token credential for the gitee.ai provider (#10243) 2024-11-05 20:29:12 +08:00
c711c5e36e feat(workflow): add configurable workflow file upload limit (#10176)
Co-authored-by: JzoNg <jzongcode@gmail.com>
2024-11-05 20:29:09 +08:00
shisaru292andYeuoly 1e27557865 fix: missing working directory parameter in script (#10226) 2024-11-05 20:28:29 +08:00
-LAN-andYeuoly 2d9632d8b9 refactor(list_operator): replace ValueError with InvalidKeyError (#10222) 2024-11-05 20:28:29 +08:00
-LAN-andYeuoly 7e42de1e7b refactor(workflow): introduce specific error handling for LLM nodes (#10221) 2024-11-05 20:28:29 +08:00
-LAN-andYeuoly bd674d27be refactor(http_request): add custom exception handling for HTTP request nodes (#10219) 2024-11-05 20:28:29 +08:00
-LAN-andYeuoly 5735761920 refactor(workflow): introduce specific exceptions for code validation (#10218) 2024-11-05 20:28:29 +08:00
-LAN-andYeuoly 405b704f02 chore(llm_node): remove unnecessary type ignore for context assignment (#10216) 2024-11-05 20:28:29 +08:00
JyongandYeuoly f38abaaa6a fix the ssrf of docx file extractor external images (#10237) 2024-11-05 20:28:28 +08:00
Hanqing ZhaoandYeuoly c8a5fee622 Modify translation (#10213) 2024-11-05 20:28:28 +08:00
fe1c0ac602 Add Lindorm as a VDB choice (#10202)
Co-authored-by: jiangzhijie <jiangzhijie.jzj@alibaba-inc.com>
2024-11-05 20:28:28 +08:00
crazywoolaandYeuoly e79c3e4531 Fix/10199 application error a client side exception has occurred see the browser console for more information (#10211) 2024-11-05 20:28:28 +08:00
-LAN-andYeuoly 3ea3df7189 refactor(validation): improve input validation logic (#10175) 2024-11-05 20:28:28 +08:00
-LAN-andYeuoly b01e7d778e chore(list_operator): refine exception handling for error specificity (#10206) 2024-11-05 20:28:28 +08:00
-LAN-andYeuoly 7c45859594 fix(document_extractor): update base exception class (#10208) 2024-11-05 20:28:27 +08:00
Kota-YamaguchiandYeuoly aa9fd76072 Feat : add LLM model indicator in prompt generator (#10187) 2024-11-05 20:28:27 +08:00
Kota-YamaguchiandYeuoly e7d947379f chore : code generator preview hint (#10188) 2024-11-05 20:28:17 +08:00
zxhlyhandYeuoly 8cd386f2c1 fix: webapp upload file (#10195) 2024-11-05 20:28:17 +08:00
-LAN-andYeuoly 987e1b9ced fix(api): replace current_user with end_user in file upload (#10194) 2024-11-05 20:28:17 +08:00
-LAN-andYeuoly 81a77d0623 feat(document_extractor): integrate unstructured API for PPTX extraction (#10180) 2024-11-05 20:28:17 +08:00
Cling_o3andYeuoly ac1f93e3d5 [fix] fix the bug that modify document name not effective (#10154) 2024-11-05 20:27:58 +08:00
-LAN-andYeuoly 0d5c0b4fe4 fix(workflow model): ensure consistent timestamp updating (#10172) 2024-11-05 20:27:57 +08:00
d1c480a7d8 fix: Cannot find declaration to go to CLEAN_DAY_SETTING (#10157)
Co-authored-by: 刘江波 <liujiangbo1@xiaomi.com>
2024-11-05 20:27:57 +08:00
Lawrence LiandYeuoly 007b561e32 feat: add gpustack model provider (#10158) 2024-11-05 20:27:57 +08:00
Yi 61a70e7a71 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-05 17:53:03 +08:00
Yi bde1261b8c chore: update installFromGitHub component 2024-11-05 17:52:47 +08:00
StyleZhang 08bb6bf858 fix: tags 2024-11-05 17:35:47 +08:00
twwu 1003190dc0 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-05 16:54:57 +08:00
twwu 4c516a50b8 fix: update type from InstalledPlugin to PluginDetail in detail-header component 2024-11-05 16:53:54 +08:00
Joel 8058a1dbe4 feat: handle update 2024-11-05 16:47:26 +08:00
Yi 8533ded335 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-05 16:36:55 +08:00
twwu 1a547b0db9 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-05 16:25:38 +08:00
twwu 0b90625e57 feat: integrate GitHub API for plugin version check and add access token support 2024-11-05 16:25:20 +08:00
Joel e989c1f3aa feat: fill update install payload 2024-11-05 16:04:52 +08:00
Joel da15a25cf5 feat: add update from github modal content 2024-11-05 15:27:08 +08:00
Joel 43254ceeb0 chore: temp types 2024-11-05 15:22:48 +08:00
Yi faf550164d Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-05 15:21:54 +08:00
Yi 1a4234347a chore: update the installFromGitHub logic 2024-11-05 15:21:45 +08:00
Joel 85947efcfa temp: change payload types 2024-11-05 15:21:07 +08:00
Joel 474ea97fc7 feat: add update to modal context 2024-11-05 15:11:55 +08:00
StyleZhang a3becde6d8 feat: plugin tags 2024-11-05 15:07:24 +08:00
Yi c40544a134 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-05 11:41:03 +08:00
Yi 4028bb4f58 chore: update installPluginFromGitHub component 2024-11-05 11:40:52 +08:00
twwu 52268460a1 fix: update dependency in Empty component to improve rendering logic 2024-11-05 11:19:04 +08:00
twwu b64298c458 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-11-05 11:05:20 +08:00
twwu 16dee11589 feat: add Empty component to installed plugin list 2024-11-05 11:05:14 +08:00
Yi 691dbf9d17 chore: update plugin from GitHub 2024-11-05 11:02:57 +08:00
JzoNg ebebbb684b endpoints list 2024-11-02 15:36:38 +08:00
JzoNg cee51ac084 need author judgement 2024-11-02 15:36:38 +08:00
JzoNg ef00ad0417 action list 2024-11-02 15:36:38 +08:00
JzoNg c37615cd33 plugin detail delete handler 2024-11-02 15:36:38 +08:00
JzoNg a387cfbc9a model list in plugin detail 2024-11-02 15:36:38 +08:00
JzoNg 04fdb4af0f plugin header operation 2024-11-02 15:36:38 +08:00
JzoNg 57f9a41e7f plugin detail selecting 2024-11-02 15:36:38 +08:00
JzoNg eb8b827906 verified tag 2024-11-02 15:36:38 +08:00
takatost c100f24f7d compatible model daemon request exception 2024-11-01 19:20:26 -07:00
Joel 99a9bf6d56 feat: support search from marketplace list 2024-11-01 18:36:24 +08:00
takatost d92cb994a9 fix voice list 2024-11-01 01:56:15 -07:00
Yeuoly 02a296bbec Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-01 16:55:45 +08:00
Yeuoly 413326905e rebase migrations 2024-11-01 16:55:07 +08:00
Yi ceae69b773 chore: update the workspace selector 2024-11-01 16:48:40 +08:00
Yeuoly 7cea6c1713 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-01 16:46:40 +08:00
Yeuoly 5605ff9803 fix voice list 2024-11-01 16:42:32 +08:00
Yeuoly 84b7a4607a fix: setup_required 2024-11-01 16:28:17 +08:00
Yeuoly 10cc4e758c Merge branch 'main' into fix/chore-fix 2024-11-01 16:23:04 +08:00
Joel 3c8548c562 feat: create tool model 2024-11-01 16:14:01 +08:00
StyleZhang 8874837dc3 feat: plugin tasks 2024-11-01 16:08:31 +08:00
Yi 40e171c2c6 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-01 15:40:06 +08:00
Yi 824ed7d6c2 chore: plugin button 2024-11-01 15:39:55 +08:00
Yeuoly 7e7d02ee15 fix: missing 'follow_redirects' argument while download plugin packages 2024-11-01 15:39:36 +08:00
Yeuoly 8070be9b76 fix: missing 'follow_redirects' argument while download plugin packages 2024-11-01 15:38:45 +08:00
JzoNg 4caa8f38bc hide plugin detail 2024-11-01 15:33:15 +08:00
Joel 5d5db7c6c1 fix: key too long breaks ui 2024-11-01 15:28:10 +08:00
Joel ca50522f80 feat: set tool params 2024-11-01 15:21:38 +08:00
takatost 01632bda70 fix 2024-11-01 00:07:41 -07:00
takatost b75dce5d0a compatible with original provider name 2024-11-01 00:07:41 -07:00
Yeuoly f1f1baae9c feat: support plugin tags 2024-11-01 15:07:11 +08:00
Yeuoly d0c53fabca Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-11-01 15:05:31 +08:00
Yeuoly 9a455949ad feat: support plugin tags 2024-11-01 15:05:23 +08:00
takatost f20c9ef763 fix 2024-11-01 00:01:05 -07:00
takatost f798add31c compatible with original provider name 2024-11-01 00:00:53 -07:00
Yi 2fd4b6e6d2 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-11-01 14:56:11 +08:00
Yi c503e8ebc9 chore: install package from GitHub 2024-11-01 14:55:56 +08:00
Joel 245bb02c88 chore: add on start to install 2024-11-01 14:51:35 +08:00
Joel 9f08206503 feat: can choose tool in agent page 2024-11-01 14:41:27 +08:00
Yeuoly ed042862f8 fix: dockerfile 2024-11-01 14:39:11 +08:00
Yeuoly b0d33487df fix: custom tool parser 2024-11-01 14:27:28 +08:00
Yeuoly 8c2dbe876f fix: custom tool parser 2024-11-01 14:26:56 +08:00
Joel 66be03f622 fix: search tools ui and some ui problem 2024-11-01 14:02:10 +08:00
Joel 04ba0a3500 Merge branch 'feat/plugins' into dev/plugin-deploy 2024-11-01 12:39:07 +08:00
Joel a273ae35f9 merge feat/plugins 2024-11-01 12:37:42 +08:00
JzoNg 1a92064260 remove unused components 2024-11-01 12:09:17 +08:00
JzoNg 7752f374e5 Revert "update model provider api responses"
This reverts commit c8dc5e4849.
2024-11-01 12:00:54 +08:00
JzoNg e7dcc53b55 Revert "load balance"
This reverts commit 378a9dd850.
2024-11-01 12:00:54 +08:00
JzoNg 22766c27c7 Revert "model list of provider"
This reverts commit 766ac3e255.
2024-11-01 12:00:54 +08:00
JzoNg c82b641357 Revert "get credentials of provider"
This reverts commit 72ef04d3e4.
2024-11-01 12:00:54 +08:00
JzoNg 1d871dae0d Revert "credentials of models"
This reverts commit 2ed73b763d.
2024-11-01 12:00:54 +08:00
JzoNg c39be7852f Revert "parameters and rules"
This reverts commit 22696fa75b.
2024-11-01 12:00:54 +08:00
JzoNg f2a5da918b Revert "other providers"
This reverts commit 339dfe5e02.
2024-11-01 12:00:54 +08:00
JzoNg 930425b896 Revert "annotation config"
This reverts commit 633768cd2a.
2024-11-01 12:00:54 +08:00
JzoNg 32e4efb524 Revert "logs"
This reverts commit 06729f6d9d.
2024-11-01 12:00:54 +08:00
JzoNg 96c3ec91af click handle of provider card 2024-11-01 12:00:54 +08:00
JzoNg f257184b00 provider card & link 2024-11-01 12:00:54 +08:00
JzoNg 581d09895e search model in provider settings 2024-11-01 12:00:54 +08:00
StyleZhang 197f1b3957 feat: search box 2024-11-01 11:26:36 +08:00
Joel 207b589458 chore: toolpicker add trigger 2024-11-01 11:22:18 +08:00
StyleZhang b5be6bacef fix: marketplace list 2024-10-31 18:54:33 +08:00
Joel bca99cf4f8 feat: tool picker 2024-10-31 18:37:50 +08:00
twwu 0e873223d7 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-10-31 18:32:32 +08:00
twwu 133b487566 feat: Enhance plugin item links and increase value display width 2024-10-31 18:32:25 +08:00
StyleZhang a9e8eb1c7e fix: marketplace list 2024-10-31 18:31:36 +08:00
twwu bf2b9bb898 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-10-31 16:44:08 +08:00
twwu 837990cb80 feat: Add loading to delete confirmation dialog 2024-10-31 16:44:04 +08:00
StyleZhang 4be2edd934 feat: plugin list tasks 2024-10-31 16:27:24 +08:00
twwu 7d4f8e0082 Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-10-31 16:20:31 +08:00
twwu 36ab121b87 feat: plugin uninstall & plugin list filtering 2024-10-31 16:20:25 +08:00
Joel 7f2980fbc0 chore: fix index show 2024-10-31 16:10:48 +08:00
Joel ae21d48132 feat: list flat view 2024-10-31 15:59:39 +08:00
StyleZhang 8af8a0f46d fix: tool list 2024-10-31 15:41:02 +08:00
Yeuoly 9a20c18869 fix: delete temp dependencies 2024-10-31 15:40:29 +08:00
Yeuoly 5ee9577d39 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-10-31 15:33:40 +08:00
Yeuoly 6fd0a55b00 fix: correct dockerfile dependencies 2024-10-31 15:32:25 +08:00
Yeuoly a196de195e Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-10-31 15:19:49 +08:00
Yeuoly bb58f5c6e5 fix: avoid None to be assigned to WorkflowToolProviderController as provider id 2024-10-31 15:18:45 +08:00
twwu 4adb61d6c7 refactor: Update marketplace API prefix in layout.tsx 2024-10-31 13:45:46 +08:00
Joel 7dd7f06f7d chore: handle icon toggle fold 2024-10-31 12:00:11 +08:00
Joel 074e660a67 feat: can add tree view 2024-10-31 11:37:55 +08:00
takatost 18edeb8e0a integrate model provider with plugin daemon 2024-10-30 18:56:52 -07:00
JzoNg 06729f6d9d logs 2024-10-31 09:06:10 +08:00
JzoNg 633768cd2a annotation config 2024-10-31 08:43:12 +08:00
JzoNg 339dfe5e02 other providers 2024-10-31 08:22:14 +08:00
JzoNg 22696fa75b parameters and rules 2024-10-31 08:22:14 +08:00
JzoNg 2ed73b763d credentials of models 2024-10-31 08:22:14 +08:00
JzoNg 72ef04d3e4 get credentials of provider 2024-10-31 08:22:14 +08:00
JzoNg 766ac3e255 model list of provider 2024-10-31 08:22:14 +08:00
JzoNg 378a9dd850 load balance 2024-10-31 08:22:14 +08:00
JzoNg c8dc5e4849 update model provider api responses 2024-10-31 08:22:14 +08:00
JzoNg 1387c6bd1c update style of agent tool list 2024-10-31 08:22:14 +08:00
JzoNg fda21f6b05 fix size of icon 2024-10-31 08:22:14 +08:00
JzoNg 8c25915d2b action panel tabs 2024-10-31 08:22:14 +08:00
JzoNg aba48749da action panel header 2024-10-31 08:22:14 +08:00
JzoNg 35a66ffe9f tool actions 2024-10-31 08:22:14 +08:00
StyleZhang 3db9174f55 fix: marketplace list 2024-10-30 17:24:46 +08:00
StyleZhang 02854b273f fix: marketplace 2024-10-30 16:36:08 +08:00
Yeuoly fb3d03b790 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-10-30 16:09:33 +08:00
Yeuoly 459cb9dd72 fix: transform plugin icon incorrect 2024-10-30 16:09:17 +08:00
StyleZhang fd0a830816 feat: marketplace list 2024-10-30 15:27:38 +08:00
StyleZhang e7fb92e169 feat: marketplace list 2024-10-30 15:16:13 +08:00
Joel 9c4e809799 chore: tiny css and i18n 2024-10-30 14:27:39 +08:00
Joel 169eb32662 chore: toolpicker ui 2024-10-30 14:24:00 +08:00
StyleZhang 0f4291bd36 merge main 2024-10-30 11:20:20 +08:00
StyleZhang 14b641557a feat: marketplace sort 2024-10-30 11:07:13 +08:00
AkaraChen 9c963d6f69 build: echarts update 2024-10-30 10:29:10 +08:00
AkaraChen 96abeda2e7 build: echarts update 2024-10-30 10:28:22 +08:00
StyleZhang 62fa90e30e feat: marketplace sort 2024-10-29 18:14:05 +08:00
Joel 7e378e219c chore: add missing i18n 2024-10-29 18:11:09 +08:00
Joel 34652010f5 feat: add market url prefix 2024-10-29 18:09:59 +08:00
AkaraChen 082f6f6a5f build: update deps 2024-10-29 17:47:06 +08:00
Joel 6f52edb157 feat: plugin permission 2024-10-29 17:18:23 +08:00
Yeuoly 60f707e5f4 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-10-29 17:16:48 +08:00
Yeuoly f9e2c738b0 fix: permission change api should not wraps a permission decorator 2024-10-29 17:16:32 +08:00
Joel 0dcbb34cab feat: handle from market install 2024-10-29 16:33:46 +08:00
StyleZhang 0886d7bb8b feat: marketplace list 2024-10-29 15:23:29 +08:00
StyleZhang e65a47cff7 feat: marketplace list 2024-10-29 15:23:29 +08:00
Joel 36c01d89c9 fix: cros promblem 2024-10-29 15:19:47 +08:00
Joel 6726ca102e feat: add get marketpalce get 2024-10-29 14:53:14 +08:00
Yeuoly 6246cf047b Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-10-29 12:32:25 +08:00
Yeuoly 739e15f88b feat: support tool plugin id 2024-10-29 12:32:11 +08:00
Joel e135707f88 chore: plugin icon not show 2024-10-29 11:57:21 +08:00
Joel f2765b9d31 feat: fetch plugin icon 2024-10-29 11:47:23 +08:00
StyleZhang 1e0877dcbf feat: marketplace list 2024-10-29 11:33:52 +08:00
StyleZhang 9a65c3391b feat: marketplace list 2024-10-29 10:51:41 +08:00
Joel ca9e23d6ea fix: check status 2024-10-28 18:36:23 +08:00
AkaraChen c4d6f9e179 build: update react-easy-crop 2024-10-28 16:46:35 +08:00
Joel 0cec6195a3 test 2024-10-28 16:33:02 +08:00
Yeuoly 19b9b91943 fix: dockerfile 2024-10-28 16:29:24 +08:00
Yeuoly e1f773d0d8 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-10-28 16:23:04 +08:00
Yeuoly 5bf86ff66d feat: support latest package identifier 2024-10-28 15:56:15 +08:00
Yeuoly c657378d06 feat: support plugin permission management 2024-10-28 15:54:34 +08:00
Joel 966d42a4db Merge branch 'main' into feat/plugins 2024-10-28 15:53:39 +08:00
AkaraChen 15c33ba7f3 build: update lexical deps 2024-10-28 15:33:22 +08:00
AkaraChen ed7f74c99c build: update i18n pkg 2024-10-28 15:32:39 +08:00
AkaraChen 1db4139b5a build: update deps
build: update classnames

build: update types

build: update uuid

build: update emoji-mart

build: update use-context-selector

build: update ui component deps
2024-10-28 15:24:44 +08:00
Yeuoly 685e8cdc7d refactor: document segment query 2024-10-28 15:07:33 +08:00
StyleZhang 0d85d44de5 feat: marketplace list 2024-10-28 11:50:45 +08:00
AkaraChen f0f1bfa5d9 build: fix eslint 2024-10-28 11:03:43 +08:00
Joel 9161ce481e Merge branch 'feat/plugins' of https://github.com/langgenius/dify into feat/plugins 2024-10-28 10:59:39 +08:00
Joel c760902e72 chore: remove useless rule 2024-10-28 10:56:52 +08:00
Joel 7c8c15ef1a test no use rule 2024-10-28 10:56:31 +08:00
Joel 765eb282f3 merge main 2024-10-28 10:51:02 +08:00
Yeuoly d36dece0af feat: support upgrade interfaces 2024-10-25 18:56:38 +08:00
AkaraChen 0e2b38dddc build: update qrcode.react 2024-10-25 18:03:25 +08:00
AkaraChen 92e4b3304c build: update deps
build: update sass

build: update lodash-es

build: update qs & js-cookie
2024-10-25 17:58:19 +08:00
Joel c777d55a1c feat: marketplace install 2024-10-25 16:46:02 +08:00
Yeuoly 5f61aa85db feat: add latest version 2024-10-25 13:52:33 +08:00
Yeuoly e5837b88e0 fix: add subpath 2024-10-25 13:26:32 +08:00
Yeuoly ffdc6f5c60 feat: support remove single item from installation task 2024-10-25 13:22:37 +08:00
AkaraChen cd27ae4319 build: update testing-library 2024-10-25 13:01:39 +08:00
AkaraChen bd82c7edac build: update storybook 2024-10-25 13:01:39 +08:00
AkaraChen d5043c6628 build: update husky & lint-staged 2024-10-25 13:01:39 +08:00
AkaraChen d9a0584052 build: update eslint & fix some case 2024-10-25 12:51:11 +08:00
Joel 3e011109ad merge main 2024-10-25 11:26:49 +08:00
Joel bdb990eb90 merge main 2024-10-25 11:26:48 +08:00
StyleZhang ae00211691 feat: marketplace types 2024-10-25 11:15:32 +08:00
StyleZhang 0ef35a0ee0 fix: enable_marketplace 2024-10-25 10:41:25 +08:00
Joel 9a9d90ad7f feat: can install 2024-10-24 17:24:46 +08:00
Joel 606fc7be0c feat: support upload pkg 2024-10-24 17:14:17 +08:00
Joel d7def41acc feat: fetch debug key api 2024-10-24 16:07:46 +08:00
AkaraChen b6a560ce86 style: lint 2024-10-24 14:52:07 +08:00
StyleZhang 25f34f6703 fix: marketplace plugin type icon 2024-10-24 14:21:12 +08:00
Yeuoly f87eeba310 Merge branch 'fix/chore-fix' into dev/plugin-deploy 2024-10-24 13:21:17 +08:00
Yeuoly 99c8f364ae fix: temp fix for empty redis password 2024-10-24 13:20:26 +08:00
Joel 7daa365564 chore: to common install comp 2024-10-24 11:10:44 +08:00
Joel 13ccd294cb fix: install error title not update 2024-10-23 17:55:25 +08:00
Yeuoly c2c07b0f4b depoly: support auto deploy 2024-10-23 17:55:11 +08:00
Joel d357f359ab feat: support install failed 2024-10-23 17:52:39 +08:00
Joel 474cedf653 feat: debug info api 2024-10-23 17:19:54 +08:00
nite-knite 5d3c88a0b3 chore: bump mermaid from 10.4.0 to 10.9.3 2024-10-23 17:02:38 +08:00
Joel ae2c76bda2 feat: install from marketplace 2024-10-23 16:42:24 +08:00
Joel c46b5f2fd0 feat: handle install search params and hide 2024-10-23 15:26:31 +08:00
Joel 2cb7b73ee7 feat: handle import from marketplace 2024-10-23 15:00:31 +08:00
Joel 8d8d5b5235 chore: handle verified 2024-10-23 11:45:36 +08:00
Joel 15acfffd60 chore: some ui and mock data 2024-10-23 11:40:56 +08:00
Yi 18a266eac2 chore: i18n for install from GitHub section 2024-10-22 18:39:23 +08:00
Joel 7751070da8 chore: install from local i18n 2024-10-22 18:11:54 +08:00
Yi fa8c3d0d7b Resolved merge conflicts by removing conflicting files 2024-10-22 17:58:41 +08:00
Yeuoly a0a1243c90 cleanup: remove hacked code 2024-10-22 17:56:13 +08:00
Yi a567cff809 chore: update the install from GitHub component 2024-10-22 17:51:14 +08:00
Yeuoly b916b4064a Merge remote-tracking branch 'origin/fix/tool-use-file' into fix/chore-fix 2024-10-22 17:47:01 +08:00
Yeuoly dea2962a79 Merge main into feat/plugin 2024-10-22 17:35:11 +08:00
Joel 583b0e9f97 chore: remove replicated types 2024-10-22 17:29:58 +08:00
Yeuoly 1450e5d5cb feat: add supports for multimodal 2024-10-22 17:26:00 +08:00
Joel 5fddb23516 feat: install progress 2024-10-22 17:21:44 +08:00
Joel 43a2d4335b fix: tool use file caused error 2024-10-22 16:51:11 +08:00
Yi 0e52971997 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-10-22 16:40:50 +08:00
Yi 1387f406a3 fix: log format 2024-10-22 16:40:27 +08:00
AkaraChen ff31f0540a style: lint 2024-10-22 15:32:58 +08:00
AkaraChen 4873e6e2a1 build: fix eslint stylistic 2024-10-22 15:32:48 +08:00
nite-knite 510ce057f7 chore: add package manager setting to vscode setting example 2024-10-22 14:18:55 +08:00
AkaraChen 0e53cc0e8c fix: eslint indent 2024-10-22 14:15:22 +08:00
Yi 0b8c896481 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-10-22 13:43:15 +08:00
Yi 15fe635465 chore: install package from GitHub 2024-10-22 13:43:01 +08:00
AkaraChen f8c3189f4d build: fix eslint undef 2024-10-22 11:43:23 +08:00
AkaraChen f215db87e3 build: fix eslint undef 2024-10-22 11:36:42 +08:00
Joel 67d02212b4 chore: pnpm 2024-10-22 11:18:30 +08:00
Joel cff9adaf8e chore: tools ts problems 2024-10-22 11:06:28 +08:00
AkaraChen cdd2a40086 style: minimium codemod 2024-10-22 02:24:59 +00:00
AkaraChen 024028bc52 build: sync eslint rule 2024-10-22 10:24:10 +08:00
AkaraChen 0ae085b48a build: add eslint common rule 2024-10-22 10:24:10 +08:00
AkaraChen 2094c54951 build: update eslint config antfu 2024-10-22 10:24:10 +08:00
AkaraChen f4f11135d3 build: using eslint flat config 2024-10-22 10:24:10 +08:00
Yeuoly 11270a7ef2 Migrate to DeclarativeBaseModel 2024-10-21 20:38:27 +08:00
Yeuoly 53e1b45d40 fix: remove .query reference of db.Model 2024-10-21 20:23:27 +08:00
Yeuoly bedbd658fe Merge main into fix/chore-fix 2024-10-21 20:01:49 +08:00
Yeuoly 7b62b5578e refactor: add manifest into upload interfaces 2024-10-21 18:48:03 +08:00
Joel 8e9d7a229d feat: scroll to view and fix action hidden 2024-10-21 18:21:45 +08:00
Joel 8f49572f85 chore: from marketplace tilte ui 2024-10-21 15:07:18 +08:00
JzoNg 5aa7696cc3 update style of action list 2024-10-21 11:34:21 +08:00
JzoNg 15dd79e822 provider detail data binding 2024-10-21 11:34:21 +08:00
JzoNg 4651ab4195 new style of provider detail 2024-10-21 11:34:21 +08:00
JzoNg 5e3160e6f6 fix title & description of tool provider 2024-10-21 11:34:21 +08:00
JzoNg 973cd126bb create & update endpoint 2024-10-21 11:34:21 +08:00
JzoNg ebaf8766ef endpoint form 2024-10-21 11:34:21 +08:00
JzoNg d2190e9c3a remove endpoint 2024-10-21 11:34:21 +08:00
JzoNg 37f55098fe switch endpoint service state 2024-10-21 11:34:21 +08:00
JzoNg b1771194cc servise of endpoints 2024-10-21 11:34:21 +08:00
JzoNg 0279bd8c75 endpoint card databing 2024-10-21 11:34:21 +08:00
JzoNg 5e077e4ce8 endpoints data binding 2024-10-21 11:34:21 +08:00
JzoNg 64067e1f20 plugin detail header operations 2024-10-21 11:34:21 +08:00
JzoNg 5295c72ca1 endpoints mock data 2024-10-21 11:34:21 +08:00
JzoNg 1ecea62052 add verified tag 2024-10-21 11:34:21 +08:00
JzoNg 307af29b65 add plugin description 2024-10-21 11:34:21 +08:00
JzoNg 10190a9aa5 plugin detail header data binding 2024-10-21 11:34:21 +08:00
JzoNg 7c5c35600c plugin detail type 2024-10-21 11:34:21 +08:00
JzoNg 63b333cdb1 modify plugin detail panel 2024-10-21 11:34:21 +08:00
JzoNg a6776190bd chore: update remix icon 2024-10-21 11:34:19 +08:00
AkaraChen 9577cbac27 build: docker use pnpm 2024-10-21 11:27:01 +08:00
AkaraChen f6ae13abad ci: migrate to pnpm 2024-10-21 11:14:30 +08:00
AkaraChen f3d501e7d5 fix: gen-icon script phantom deps 2024-10-21 10:43:52 +08:00
AkaraChen 2eab8fcc33 build: switch to pnpm 2024-10-21 10:43:52 +08:00
Joel bdb81fe20d feat: choose tool sticky 2024-10-18 18:18:59 +08:00
Yi 0f60fe7f2a chore: update workspace name (truncated for long name) 2024-10-18 14:17:53 +08:00
Yi 425f624de5 chore: add plugin panel 2024-10-18 14:02:40 +08:00
Yi b1919745e2 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-10-18 14:01:34 +08:00
twwu 9a242bcac9 Merge branch 'main' into feat/plugins 2024-10-18 09:59:43 +08:00
Yeuoly ccbe42eb5f feat: add plugin id into tool api entities 2024-10-17 20:46:29 +08:00
Yeuoly 45f8651a3d feat: support backwards invoke summary 2024-10-17 19:44:30 +08:00
Yeuoly 7754431a34 feat: support plugin max package size 2024-10-17 18:44:16 +08:00
Yi a6109a60b8 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-10-17 15:22:08 +08:00
Yi 28f7bbf83a chore: installation progress bar 2024-10-17 15:21:56 +08:00
Joel cac04c5f3c refactor: chagne card to client component 2024-10-17 15:06:06 +08:00
Yeuoly fa7215cfea Merge branch 'main' into fix/chore-fix 2024-10-17 13:46:43 +08:00
Yeuoly 678c89891a feat: support verified 2024-10-17 13:40:33 +08:00
Yeuoly beebcbd962 feat: add description 2024-10-17 12:59:11 +08:00
Joel 18f5f9cc37 feat: plugin upgrade 2024-10-16 18:05:55 +08:00
Joel 1787c5c93f chore: handle tag name too long 2024-10-16 16:39:47 +08:00
Joel f981494613 feat: plugin support emoji icon 2024-10-16 16:28:19 +08:00
Joel fbc853af92 feat: remove config 2024-10-16 16:28:18 +08:00
StyleZhang 1a64c660ba enable marketplace 2024-10-16 15:50:18 +08:00
Yeuoly 8495ed3348 add conversation id, app id and message id into plugin session 2024-10-16 15:10:50 +08:00
Yeuoly 31cca4a849 fix: add marketplace switch 2024-10-16 14:47:48 +08:00
Yeuoly 43ffccc8fd fix: install plugins 2024-10-16 14:02:05 +08:00
Yeuoly a81293cf5a feat: add category for plugins 2024-10-16 13:03:50 +08:00
Joel 846555af1b fix: action buttion ui 2024-10-16 11:45:25 +08:00
Joel bca94854f7 feat: plugin info 2024-10-16 11:30:04 +08:00
Joel 1bd70bd8bf chore: copy button 2024-10-16 11:05:51 +08:00
Joel d1dcd39191 feat: add debug info i18n and extract common to components 2024-10-16 10:52:16 +08:00
Joel 35384bda41 chore: refactor card loading 2024-10-15 22:52:57 +08:00
Joel 89fb6eb648 chore: set hideCornerMark to optional 2024-10-15 21:45:30 +08:00
Joel aa61a890b2 chore: change downloadCount to optional 2024-10-15 21:43:20 +08:00
Joel 31ece363c3 chore: chagne mangament attr name 2024-10-15 21:35:56 +08:00
Joel 70a5d78cc5 chore: priviege i18n 2024-10-15 21:31:06 +08:00
Joel 57f4dfdb6f feat: add permission data logic 2024-10-15 19:20:59 +08:00
Yi aa9028a607 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-10-15 15:48:05 +08:00
Yi d83f94c55c fix: set constrain for uploading packages only works in the Plugins tab 2024-10-15 15:47:54 +08:00
StyleZhang a8c5e0b0b0 tool list item click 2024-10-15 15:13:00 +08:00
Yi 177e8cbf73 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-10-15 14:57:37 +08:00
Yi 23828fd15a Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-10-15 14:57:11 +08:00
StyleZhang 2cc37ac8e5 tool list 2024-10-15 14:57:00 +08:00
Yi c9ee1e9ff2 feat: install difypkg ui 2024-10-15 14:56:59 +08:00
Joel 4f10f5d5f4 chore: hover show action 2024-10-15 11:57:44 +08:00
Yi c48c84674e Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-10-15 11:02:45 +08:00
Yi 1e9fbbf41b fix: dynamic sub header color 2024-10-15 11:02:25 +08:00
StyleZhang 4dd144ce43 tools list 2024-10-15 10:41:10 +08:00
Yi a387ff1c38 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-10-14 18:43:24 +08:00
Yi a9e367e6de feat: use-uploader hook 2024-10-14 18:43:08 +08:00
Joel e2fec587f8 feat: from marketplace 2024-10-14 18:35:13 +08:00
Yeuoly 276701e1b7 refactor: plugin installation 2024-10-14 17:52:29 +08:00
Yeuoly 8e1cf3233c fix: missing openai moderation 2024-10-14 16:42:36 +08:00
Yeuoly dd551e6ca8 Ruff: reformatter 2024-10-14 16:25:51 +08:00
Yeuoly ae1eeb9b2a Mergin main into fix/chore-fix 2024-10-14 16:22:12 +08:00
StyleZhang 39a6f0943d marketplace 2024-10-14 12:38:53 +08:00
JzoNg 684896d100 merge main 2024-10-14 10:29:52 +08:00
JzoNg 54f911f6cd endpoints 2024-10-13 10:49:55 +08:00
Joel 0e5c16d0c2 feat: view to ui and fix some ui promblem 2024-10-12 18:15:11 +08:00
Joel b8cd6ea478 feat: support view choose 2024-10-12 17:36:35 +08:00
JzoNg fc61fd0f50 action list 2024-10-12 17:08:45 +08:00
JzoNg 2fbfc988c4 plugin panel detail 2024-10-12 16:37:57 +08:00
JzoNg 99f5fea001 plugin detail panel header 2024-10-12 16:37:57 +08:00
StyleZhang ecd2a1be9f marketplace 2024-10-12 16:34:18 +08:00
Joel 49ee9ca5f1 feat: tool item support action 2024-10-12 16:04:16 +08:00
Joel 6d0eef12b1 feat: split tools data to out and add demo 2024-10-12 14:30:46 +08:00
StyleZhang c1e0a939b0 marketplace 2024-10-12 12:46:49 +08:00
JzoNg 060a894bd1 interaction of plugin detail panel 2024-10-12 12:36:29 +08:00
JzoNg c75e02b5b2 update provider card 2024-10-12 12:36:29 +08:00
StyleZhang fcf43ee845 plugin page context 2024-10-12 11:33:12 +08:00
StyleZhang 466f61d044 relocate file 2024-10-12 11:05:03 +08:00
StyleZhang 27ae74af50 hook 2024-10-12 11:03:00 +08:00
Joel 8dd941e3d2 chore: instal plug add tag 2024-10-11 18:18:32 +08:00
Joel dec4bf6b98 fix: install modal item server 2024-10-11 18:06:23 +08:00
Joel e2c33fc40f fix: plugin item i18n 2024-10-11 18:05:45 +08:00
Yi c74e59d1f4 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-10-11 17:28:27 +08:00
Yi 1fcb902715 feat: add cards to "install from marketplace" 2024-10-11 17:25:33 +08:00
JzoNg c08f98218c hide search in other pages 2024-10-11 17:13:28 +08:00
Yi c6377f6e38 fix: naming styles 2024-10-11 16:29:07 +08:00
Yi 3cb0a5bd68 Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-10-11 16:28:04 +08:00
Yi 95777d23e0 fix: naming styles 2024-10-11 16:27:31 +08:00
JzoNg e7dc16fd08 provider card 2024-10-11 16:21:19 +08:00
JzoNg 495dec143c unconfigured provider 2024-10-11 16:21:19 +08:00
JzoNg 4cc6dfa232 new style of provider card 2024-10-11 16:21:18 +08:00
JzoNg d1452d4af4 no provider installed 2024-10-11 16:21:18 +08:00
JzoNg d68ca56b3a system default model 2024-10-11 16:21:18 +08:00
JzoNg 49856d8d17 setting content header & close button 2024-10-11 16:21:18 +08:00
JzoNg 902de72cc0 new style of settings 2024-10-11 16:21:18 +08:00
StyleZhang 76f6b8d104 marketplace 2024-10-11 16:15:24 +08:00
StyleZhang f111e605c4 marketplace 2024-10-11 15:27:14 +08:00
Joel b358ed3a5b fix: init workflow image crash 2024-10-11 14:31:14 +08:00
Joel 88dbf639e0 chore: enchance locale props 2024-10-11 14:24:43 +08:00
Joel aa8b525b48 fix: icon tsx to router problem 2024-10-11 14:10:24 +08:00
Yi c990bc61db feat: install plugins (partial) 2024-10-11 12:39:27 +08:00
Junyan QinandGitHub b58f8dd7b4 feat: download pkg from marketplace (#9184) 2024-10-11 02:00:02 +08:00
Yeuoly 118fa66567 feat: backwards invoke tools 2024-10-10 18:09:06 +08:00
Joel 6d7588f236 chore: fix ui 2024-10-10 17:53:13 +08:00
Joel 8257c7bf02 chore: remove useless data 2024-10-10 17:49:23 +08:00
Joel 946068967b feat: finish card components 2024-10-10 17:47:04 +08:00
Yeuoly 699d41deec fix: add source to plugin entity 2024-10-10 16:47:25 +08:00
Yeuoly dd0462c1dc feat: support two install source 2024-10-10 16:35:36 +08:00
Joel 19f5684960 feat: add label and fix some ui problem 2024-10-10 11:29:11 +08:00
Joel 6d62840aff chore: split card component 2024-10-10 10:40:26 +08:00
Joel ab868ac979 fix: error igm 2024-10-10 10:25:25 +08:00
Joel 1d74e693ea chore: fix imge name 2024-10-10 10:22:18 +08:00
Yeuoly a470e0e60e fix: missing detailed paths of endpoints 2024-10-10 00:12:46 +08:00
Yeuoly 2622159763 feat: support verify signature 2024-10-09 23:13:01 +08:00
Yeuoly dfaf639790 feat: support endpoint url template 2024-10-09 22:58:36 +08:00
Yeuoly ae96f66a08 feat: support list endpoints for single plugin, fix: failed to clear endpoint credentials 2024-10-09 22:33:18 +08:00
Joel fa43d4202f feat: plugin item 2024-10-09 18:36:15 +08:00
Joel 6b29860788 feat: add installed 2024-10-09 18:12:14 +08:00
Joel 36800eeaba feat: base card component 2024-10-09 17:51:54 +08:00
Yi 67acd174ac add different styles to plugins and discover 2024-10-09 15:55:33 +08:00
StyleZhang b5edc64b2a plugin type switch 2024-10-09 15:06:09 +08:00
Yi d00b2724cc Merge branch 'feat/plugins' of github.com:langgenius/dify into feat/plugins 2024-10-09 12:53:56 +08:00
Yi 43f87c0b86 make the drop plugin only appears when the user selects "plugins" 2024-10-09 12:53:43 +08:00
Joel 7a43f48c95 chore: add test page 2024-10-09 11:35:16 +08:00
Yeuoly 570b7d18ac fix: endpoint apis 2024-10-08 23:48:38 +08:00
Yeuoly a9c21ef929 feat: uninstall plugins 2024-10-08 22:38:33 +08:00
Yeuoly e27a03ae15 feat: support install plugin 2024-10-08 21:28:59 +08:00
StyleZhang 58a913b09d marketplace 2024-10-08 17:58:05 +08:00
Joel cd03795f2c chore: add endpoint types 2024-10-08 15:44:52 +08:00
Yeuoly 56b7853afe feat: compat tool provider credentials to updated data 2024-09-30 23:22:23 +08:00
takatost e12f4009d3 feat: optimize icon url 2024-09-30 17:46:40 +08:00
Yeuoly 6dfc31a542 refactor: credentials schemas to array 2024-09-30 17:39:13 +08:00
Yeuoly c9f80b46a1 fix: add endpoint name 2024-09-30 16:57:09 +08:00
Joel 36f8b5711d feat: plugin types 2024-09-30 15:29:53 +08:00
Yeuoly 0025b27200 fix: tool invocation logs 2024-09-29 21:09:01 +08:00
Yeuoly 0dd05d7b6d feat: tool output schema 2024-09-29 20:58:07 +08:00
takatost 7c83d5ce76 feat: add dockerignore items 2024-09-29 20:16:21 +08:00
takatost a57f60a6e0 feat: remove unused codes 2024-09-29 19:47:47 +08:00
Yeuoly 2f36692bf9 fix: get tool runtime parameters 2024-09-29 19:37:03 +08:00
Joel f9c48e9ea9 fix: eslint to find top dir 2024-09-29 18:27:36 +08:00
takatost bcdb407be8 feat: remove unused codes 2024-09-29 18:24:33 +08:00
Yeuoly d4e007f9db feat: support get tool runtime parameters 2024-09-29 18:19:03 +08:00
takatost 8563155d1b feat: remove unused codes 2024-09-29 18:18:01 +08:00
takatost 8236373498 feat: remove unused codes 2024-09-29 18:16:21 +08:00
Yeuoly 196bfeaaf4 Merge branch 'main' into fix/chore-fix 2024-09-29 17:14:10 +08:00
Yeuoly 957ab093c9 enhancement: reduce requests to plugin daemon 2024-09-29 17:07:40 +08:00
Yeuoly e9e5c8806a refactor: using DeclarativeBase as parent class of models, refactored tools 2024-09-29 17:00:58 +08:00
Yeuoly c8bc3892b3 refactor: invoke tool from dify 2024-09-29 14:44:22 +08:00
Yeuoly 735e57b73a fix: transform generic error message into correct type 2024-09-29 13:46:16 +08:00
Yeuoly 635a53ea38 fix: import undefined types 2024-09-29 13:23:14 +08:00
Yeuoly 7b76b1ff82 Merge fix/chore-fix into fix/chore-fix 2024-09-29 13:12:22 +08:00
takatost 47c8824be6 feat: move model request to plugin daemon 2024-09-29 00:15:17 +08:00
takatost 1c3213184e feat: move model request to plugin daemon 2024-09-29 00:15:14 +08:00
Yeuoly d9cced8419 Merge branch 'main' into fix/chore-fix 2024-09-28 20:18:28 +08:00
Yeuoly c3359a9291 refactor: using plugin id to dispatch request instead 2024-09-27 21:48:48 +08:00
JzoNg 3b48f8c98e Merge branch 'main' into tp 2024-09-27 16:47:57 +08:00
JzoNg cef1010cb5 style update 2024-09-27 16:47:01 +08:00
Yeuoly 2da32e49d0 fix: tests 2024-09-26 17:51:13 +08:00
Yeuoly 1837692a66 fix: sse error message 2024-09-26 17:40:27 +08:00
Yeuoly 5dcd25a613 fix: missing error message 2024-09-26 17:22:39 +08:00
Yeuoly 507fff0259 fix: tts file was deleted before invocation 2024-09-26 15:47:16 +08:00
Yeuoly 0ad9dbea63 feat: backwards invoke model 2024-09-26 15:38:22 +08:00
Joel cb4875a3a7 chore: split the common tailwind config 2024-09-26 15:06:36 +08:00
Yeuoly 4c28034224 refactor: encryption 2024-09-26 14:51:10 +08:00
Yeuoly 1d575524c3 fix: missing user id 2024-09-26 14:20:05 +08:00
Yeuoly dc255cc154 Merge main into feat/plugin 2024-09-26 12:59:06 +08:00
Yeuoly ea497f828f feat: endpoint management 2024-09-26 12:49:00 +08:00
Yeuoly 153dc5b3f3 feat: endpoint apis 2024-09-26 10:26:45 +08:00
Yeuoly a91951b374 feat: invoke node 2024-09-24 20:15:13 +08:00
Yeuoly 68c10a1672 feat: add backwards invoke node api 2024-09-24 18:03:48 +08:00
Yeuoly 592f85f7a9 formatter 2024-09-24 16:40:42 +08:00
Yeuoly cda9f6ec6b Merge main into fix/chore-fix 2024-09-24 16:38:38 +08:00
Yeuoly 64706c709c fix 2024-09-24 16:35:01 +08:00
Yeuoly 9722e6bcb1 fix: allow duplicate tool providers 2024-09-24 16:33:19 +08:00
Yeuoly 1907d791e1 enhance: add gzip 2024-09-24 16:15:50 +08:00
Yeuoly fb3a701c86 fix: stream with empty line 2024-09-24 16:02:01 +08:00
StyleZhang bbca708832 add marketplace card 2024-09-24 11:18:34 +08:00
Yeuoly 947bfdc807 feat: validate credentials 2024-09-23 21:13:02 +08:00
Yeuoly 7a3e756020 refactor: list tools 2024-09-23 18:06:16 +08:00
Yeuoly 435e71eb60 refactor 2024-09-23 13:09:46 +08:00
JzoNg 05aec43ee3 Merge branch 'main' into tp 2024-09-23 11:39:46 +08:00
Yeuoly 91cb80f795 refactor: tool 2024-09-20 23:48:48 +08:00
Yeuoly 3c1d32e3ac feat: uninstall plugin 2024-09-20 21:50:44 +08:00
Yeuoly eef79a5196 feat: support install plugin 2024-09-20 21:35:19 +08:00
Yeuoly 2223dfb266 feat: get debugging key 2024-09-20 15:08:39 +08:00
Yeuoly 9693b5ad0c feat: debugging key 2024-09-20 14:43:01 +08:00
Yeuoly d4bf575d0a impl: basic plugin manager 2024-09-20 13:55:09 +08:00
Yeuoly 73ce692e24 feat: add inner api key 2024-09-20 13:32:11 +08:00
Yeuoly 661392eaef refactor: tool 2024-09-20 02:25:14 +08:00
Yeuoly c472ea6c67 fix: pydantic 2024-09-19 18:02:24 +08:00
Yeuoly 4eaba3049a Merge main 2024-09-19 17:54:08 +08:00
Yi e8127756e0 Merge branch 'main' of github.com:langgenius/dify into feat/plugins 2024-09-18 20:57:52 +08:00
Yi 792595a46f update page header 2024-09-18 18:32:33 +08:00
Yi d7d7281c93 feat: plugin homepage 2024-09-16 18:58:39 +08:00
Yi 21193c2fbf update the plugins page 2024-09-14 17:09:25 +08:00
Yeuoly 00d1c45518 Merge main 2024-09-14 02:47:01 +08:00
Yeuoly 87c746f6bb tmp 2024-09-14 01:26:22 +08:00
Yeuoly 70c001436e support variable 2024-09-10 18:13:33 +08:00
Yeuoly cf73374c1b refactor: stream output 2024-09-10 17:16:55 +08:00
Yeuoly b0d53c0ac4 Merge main 2024-09-10 15:42:59 +08:00
Yeuoly 9c7bcd5abc Merge main 2024-09-10 14:05:20 +08:00
Yeuoly b7c5abc5dd reformatter 2024-08-30 23:29:04 +08:00
Yeuoly de01ca8d55 feat: inner api encrypt 2024-08-30 21:25:58 +08:00
Yeuoly 60e75dc748 fix: linter 2024-08-30 21:11:39 +08:00
Yeuoly 279dee485d feat: type 2024-08-30 21:10:19 +08:00
Yeuoly db8bf2a85e Merge branch 'main' into feat/plugin 2024-08-30 18:21:22 +08:00
Yeuoly 46ba16fe90 fix: reformatter 2024-08-30 18:21:03 +08:00
Yeuoly 886a160115 fix: invoke tool streamingly 2024-08-30 18:11:38 +08:00
Yeuoly cf4e9f317e refactor: tool models 2024-08-30 15:55:10 +08:00
Yeuoly 1fa3b9cfd8 refactor tools 2024-08-30 14:23:14 +08:00
Yeuoly 50a5cfe56a fix: endpoint using default user 2024-08-29 21:48:20 +08:00
Yeuoly ece82b87bf feat: invoke app 2024-08-29 21:14:23 +08:00
Yeuoly 12ea085e22 feat: implement invoke app args 2024-08-29 20:50:36 +08:00
Yeuoly 41ed2e0cc2 feat: backwards invoke app 2024-08-29 20:17:17 +08:00
Yeuoly 113ff27d07 fix: types 2024-08-29 20:06:14 +08:00
Yeuoly ec711d094d refactor: enforce return object in app generator 2024-08-29 19:49:57 +08:00
Yeuoly a073de44e9 Merge branch 'main' into feat/plugin 2024-08-29 17:08:44 +08:00
Yeuoly 6ce02b07d3 feat: add type annatation 2024-08-29 14:23:19 +08:00
Yeuoly f47712beae feat: add type annatation 2024-08-29 14:18:00 +08:00
Yeuoly 4a8d3c54ca fix: workflow as tool type 2024-08-29 14:09:47 +08:00
Yeuoly c8b0160ea9 fix: tool type 2024-08-29 14:06:10 +08:00
Yeuoly 531ffaec4f fix: tool node 2024-08-29 13:56:48 +08:00
Yeuoly c28998a6f0 refactor: tool message transformer 2024-08-29 13:42:31 +08:00
Yeuoly 4b4741f7ed Merge main into feat/plugin 2024-08-29 13:09:13 +08:00
Yeuoly 25b8a512bf feat: invoke app 2024-08-29 12:55:00 +08:00
Yeuoly 02d26818ad Merge branch 'main' into feat/plugin 2024-07-31 14:51:36 +08:00
Yeuoly 31e8b134d1 feat: backwards invoke llm 2024-07-29 22:08:14 +08:00
Yeuoly d52476c1c9 feat: support backwards invocation 2024-07-29 18:57:34 +08:00
Yeuoly f29b44acd8 feat: support plugin inner api 2024-07-29 16:40:04 +08:00
Yeuoly ed7fcc5f7d Merge branch 'main' into feat/plugin 2024-07-29 16:07:19 +08:00
Yeuoly c6f34f5c17 Merge branch 'main' into feat/plugin 2024-07-15 16:03:11 +08:00
Yeuoly e1db77eec2 fix 2024-07-15 16:00:11 +08:00
Yeuoly 563d81277b refactor: tool response to generator 2024-07-09 15:37:56 +08:00
Yeuoly 364df36ac4 feat: plugin call dify 2024-07-08 22:37:20 +08:00
14176 changed files with 351688 additions and 2225178 deletions
-168
View File
@@ -1,168 +0,0 @@
---
name: backend-code-review
description: Review backend code for quality, security, maintainability, and best practices based on established checklist rules. Use when the user requests a review, analysis, or improvement of backend files (e.g., `.py`) under the `api/` directory. Do NOT use for frontend files (e.g., `.tsx`, `.ts`, `.js`). Supports pending-change review, code snippets review, and file-focused review.
---
# Backend Code Review
## When to use this skill
Use this skill whenever the user asks to **review, analyze, or improve** backend code (e.g., `.py`) under the `api/` directory. Supports the following review modes:
- **Pending-change review**: when the user asks to review current changes (inspect staged/working-tree files slated for commit to get the changes).
- **Code snippets review**: when the user pastes code snippets (e.g., a function/class/module excerpt) into the chat and asks for a review.
- **File-focused review**: when the user points to specific files and asks for a review of those files (one file or a small, explicit set of files, e.g., `api/...`, `api/app.py`).
Do NOT use this skill when:
- The request is about frontend code or UI (e.g., `.tsx`, `.ts`, `.js`, `web/`).
- The user is not asking for a review/analysis/improvement of backend code.
- The scope is not under `api/` (unless the user explicitly asks to review backend-related changes outside `api/`).
## How to use this skill
Follow these steps when using this skill:
1. **Identify the review mode** (pending-change vs snippet vs file-focused) based on the users input. Keep the scope tight: review only what the user provided or explicitly referenced.
2. Follow the rules defined in **Checklist** to perform the review. If no Checklist rule matches, apply **General Review Rules** as a fallback to perform the best-effort review.
3. Compose the final output strictly follow the **Required Output Format**.
Notes when using this skill:
- Always include actionable fixes or suggestions (including possible code snippets).
- Use best-effort `File:Line` references when a file path and line numbers are available; otherwise, use the most specific identifier you can.
## Checklist
- db schema design: if the review scope includes code/files under `api/models/` or `api/migrations/`, follow [references/db-schema-rule.md](references/db-schema-rule.md) to perform the review
- architecture: if the review scope involves controller/service/core-domain/libs/model layering, dependency direction, or moving responsibilities across modules, follow [references/architecture-rule.md](references/architecture-rule.md) to perform the review
- repositories abstraction: if the review scope contains table/model operations (e.g., `select(...)`, `session.execute(...)`, joins, CRUD) and is not under `api/repositories`, `api/core/repositories`, or `api/extensions/*/repositories/`, follow [references/repositories-rule.md](references/repositories-rule.md) to perform the review
- sqlalchemy patterns: if the review scope involves SQLAlchemy session/query usage, db transaction/crud usage, or raw SQL usage, follow [references/sqlalchemy-rule.md](references/sqlalchemy-rule.md) to perform the review
## General Review Rules
### 1. Security Review
Check for:
- SQL injection vulnerabilities
- Server-Side Request Forgery (SSRF)
- Command injection
- Insecure deserialization
- Hardcoded secrets/credentials
- Improper authentication/authorization
- Insecure direct object references
### 2. Performance Review
Check for:
- N+1 queries
- Missing database indexes
- Memory leaks
- Blocking operations in async code
- Missing caching opportunities
### 3. Code Quality Review
Check for:
- Code forward compatibility
- Code duplication (DRY violations)
- Functions doing too much (SRP violations)
- Deep nesting / complex conditionals
- Magic numbers/strings
- Poor naming
- Missing error handling
- Incomplete type coverage
### 4. Testing Review
Check for:
- Missing test coverage for new code
- Tests that don't test behavior
- Flaky test patterns
- Missing edge cases
## Required Output Format
When this skill invoked, the response must exactly follow one of the two templates:
### Template A (any findings)
```markdown
# Code Review Summary
Found <X> critical issues need to be fixed:
## 🔴 Critical (Must Fix)
### 1. <brief description of the issue>
FilePath: <path> line <line>
<relevant code snippet or pointer>
#### Explanation
<detailed explanation and references of the issue>
#### Suggested Fix
1. <brief description of suggested fix>
2. <code example> (optional, omit if not applicable)
---
... (repeat for each critical issue) ...
Found <Y> suggestions for improvement:
## 🟡 Suggestions (Should Consider)
### 1. <brief description of the suggestion>
FilePath: <path> line <line>
<relevant code snippet or pointer>
#### Explanation
<detailed explanation and references of the suggestion>
#### Suggested Fix
1. <brief description of suggested fix>
2. <code example> (optional, omit if not applicable)
---
... (repeat for each suggestion) ...
Found <Z> optional nits:
## 🟢 Nits (Optional)
### 1. <brief description of the nit>
FilePath: <path> line <line>
<relevant code snippet or pointer>
#### Explanation
<explanation and references of the optional nit>
#### Suggested Fix
- <minor suggestions>
---
... (repeat for each nits) ...
## ✅ What's Good
- <Positive feedback on good patterns>
```
- If there are no critical issues or suggestions or option nits or good points, just omit that section.
- If the issue number is more than 10, summarize as "Found 10+ critical issues/suggestions/optional nits" and only output the first 10 items.
- Don't compress the blank lines between sections; keep them as-is for readability.
- If there is any issue requires code changes, append a brief follow-up question to ask whether the user wants to apply the fix(es) after the structured output. For example: "Would you like me to use the Suggested fix(es) to address these issues?"
### Template B (no issues)
```markdown
## Code Review Summary
✅ No issues found.
```
@@ -1,91 +0,0 @@
# Rule Catalog — Architecture
## Scope
- Covers: controller/service/core-domain/libs/model layering, dependency direction, responsibility placement, observability-friendly flow.
## Rules
### Keep business logic out of controllers
- Category: maintainability
- Severity: critical
- Description: Controllers should parse input, call services, and return serialized responses. Business decisions inside controllers make behavior hard to reuse and test.
- Suggested fix: Move domain/business logic into the service or core/domain layer. Keep controller handlers thin and orchestration-focused.
- Example:
- Bad:
```python
@bp.post("/apps/<app_id>/publish")
def publish_app(app_id: str):
payload = request.get_json() or {}
if payload.get("force") and current_user.role != "admin":
raise ValueError("only admin can force publish")
app = App.query.get(app_id)
app.status = "published"
db.session.commit()
return {"result": "ok"}
```
- Good:
```python
@bp.post("/apps/<app_id>/publish")
def publish_app(app_id: str):
payload = PublishRequest.model_validate(request.get_json() or {})
app_service.publish_app(app_id=app_id, force=payload.force, actor_id=current_user.id)
return {"result": "ok"}
```
### Preserve layer dependency direction
- Category: best practices
- Severity: critical
- Description: Controllers may depend on services, and services may depend on core/domain abstractions. Reversing this direction (for example, core importing controller/web modules) creates cycles and leaks transport concerns into domain code.
- Suggested fix: Extract shared contracts into core/domain or service-level modules and make upper layers depend on lower, not the reverse.
- Example:
- Bad:
```python
# core/policy/publish_policy.py
from controllers.console.app import request_context
def can_publish() -> bool:
return request_context.current_user.is_admin
```
- Good:
```python
# core/policy/publish_policy.py
def can_publish(role: str) -> bool:
return role == "admin"
# service layer adapts web/user context to domain input
allowed = can_publish(role=current_user.role)
```
### Keep libs business-agnostic
- Category: maintainability
- Severity: critical
- Description: Modules under `api/libs/` should remain reusable, business-agnostic building blocks. They must not encode product/domain-specific rules, workflow orchestration, or business decisions.
- Suggested fix:
- If business logic appears in `api/libs/`, extract it into the appropriate `services/` or `core/` module and keep `libs` focused on generic, cross-cutting helpers.
- Keep `libs` dependencies clean: avoid importing service/controller/domain-specific modules into `api/libs/`.
- Example:
- Bad:
```python
# api/libs/conversation_filter.py
from services.conversation_service import ConversationService
def should_archive_conversation(conversation, tenant_id: str) -> bool:
# Domain policy and service dependency are leaking into libs.
service = ConversationService()
if service.has_paid_plan(tenant_id):
return conversation.idle_days > 90
return conversation.idle_days > 30
```
- Good:
```python
# api/libs/datetime_utils.py (business-agnostic helper)
def older_than_days(idle_days: int, threshold_days: int) -> bool:
return idle_days > threshold_days
# services/conversation_service.py (business logic stays in service/core)
from libs.datetime_utils import older_than_days
def should_archive_conversation(conversation, tenant_id: str) -> bool:
threshold_days = 90 if has_paid_plan(tenant_id) else 30
return older_than_days(conversation.idle_days, threshold_days)
```
@@ -1,157 +0,0 @@
# Rule Catalog — DB Schema Design
## Scope
- Covers: model/base inheritance, schema boundaries in model properties, tenant-aware schema design, index redundancy checks, dialect portability in models, and cross-database compatibility in migrations.
- Does NOT cover: session lifecycle, transaction boundaries, and query execution patterns (handled by `sqlalchemy-rule.md`).
## Rules
### Do not query other tables inside `@property`
- Category: [maintainability, performance]
- Severity: critical
- Description: A model `@property` must not open sessions or query other tables. This hides dependencies across models, tightly couples schema objects to data access, and can cause N+1 query explosions when iterating collections.
- Suggested fix:
- Keep model properties pure and local to already-loaded fields.
- Move cross-table data fetching to service/repository methods.
- For list/batch reads, fetch required related data explicitly (join/preload/bulk query) before rendering derived values.
- Example:
- Bad:
```python
class Conversation(TypeBase):
__tablename__ = "conversations"
@property
def app_name(self) -> str:
with Session(db.engine, expire_on_commit=False) as session:
app = session.execute(select(App).where(App.id == self.app_id)).scalar_one()
return app.name
```
- Good:
```python
class Conversation(TypeBase):
__tablename__ = "conversations"
@property
def display_title(self) -> str:
return self.name or "Untitled"
# Service/repository layer performs explicit batch fetch for related App rows.
```
### Prefer including `tenant_id` in model definitions
- Category: maintainability
- Severity: suggestion
- Description: In multi-tenant domains, include `tenant_id` in schema definitions whenever the entity belongs to tenant-owned data. This improves data isolation safety and keeps future partitioning/sharding strategies practical as data volume grows.
- Suggested fix:
- Add a `tenant_id` column and ensure related unique/index constraints include tenant dimension when applicable.
- Propagate `tenant_id` through service/repository contracts to keep access paths tenant-aware.
- Exception: if a table is explicitly designed as non-tenant-scoped global metadata, document that design decision clearly.
- Example:
- Bad:
```python
from sqlalchemy.orm import Mapped
class Dataset(TypeBase):
__tablename__ = "datasets"
id: Mapped[str] = mapped_column(StringUUID, primary_key=True)
name: Mapped[str] = mapped_column(sa.String(255), nullable=False)
```
- Good:
```python
from sqlalchemy.orm import Mapped
class Dataset(TypeBase):
__tablename__ = "datasets"
id: Mapped[str] = mapped_column(StringUUID, primary_key=True)
tenant_id: Mapped[str] = mapped_column(StringUUID, nullable=False, index=True)
name: Mapped[str] = mapped_column(sa.String(255), nullable=False)
```
### Detect and avoid duplicate/redundant indexes
- Category: performance
- Severity: suggestion
- Description: Review index definitions for leftmost-prefix redundancy. For example, index `(a, b, c)` can safely cover most lookups for `(a, b)`. Keeping both may increase write overhead and can mislead the optimizer into suboptimal execution plans.
- Suggested fix:
- Before adding an index, compare against existing composite indexes by leftmost-prefix rules.
- Drop or avoid creating redundant prefixes unless there is a proven query-pattern need.
- Apply the same review standard in both model `__table_args__` and migration index DDL.
- Example:
- Bad:
```python
__table_args__ = (
sa.Index("idx_msg_tenant_app", "tenant_id", "app_id"),
sa.Index("idx_msg_tenant_app_created", "tenant_id", "app_id", "created_at"),
)
```
- Good:
```python
__table_args__ = (
# Keep the wider index unless profiling proves a dedicated short index is needed.
sa.Index("idx_msg_tenant_app_created", "tenant_id", "app_id", "created_at"),
)
```
### Avoid PostgreSQL-only dialect usage in models; wrap in `models.types`
- Category: maintainability
- Severity: critical
- Description: Model/schema definitions should avoid PostgreSQL-only constructs directly in business models. When database-specific behavior is required, encapsulate it in `api/models/types.py` using both PostgreSQL and MySQL dialect implementations, then consume that abstraction from model code.
- Suggested fix:
- Do not directly place dialect-only types/operators in model columns when a portable wrapper can be used.
- Add or extend wrappers in `models.types` (for example, `AdjustedJSON`, `LongText`, `BinaryData`) to normalize behavior across PostgreSQL and MySQL.
- Example:
- Bad:
```python
from sqlalchemy.dialects.postgresql import JSONB
from sqlalchemy.orm import Mapped
class ToolConfig(TypeBase):
__tablename__ = "tool_configs"
config: Mapped[dict] = mapped_column(JSONB, nullable=False)
```
- Good:
```python
from sqlalchemy.orm import Mapped
from models.types import AdjustedJSON
class ToolConfig(TypeBase):
__tablename__ = "tool_configs"
config: Mapped[dict] = mapped_column(AdjustedJSON(), nullable=False)
```
### Guard migration incompatibilities with dialect checks and shared types
- Category: maintainability
- Severity: critical
- Description: Migration scripts under `api/migrations/versions/` must account for PostgreSQL/MySQL incompatibilities explicitly. For dialect-sensitive DDL or defaults, branch on the active dialect (for example, `conn.dialect.name == "postgresql"`), and prefer reusable compatibility abstractions from `models.types` where applicable.
- Suggested fix:
- In migration upgrades/downgrades, bind connection and branch by dialect for incompatible SQL fragments.
- Reuse `models.types` wrappers in column definitions when that keeps behavior aligned with runtime models.
- Avoid one-dialect-only migration logic unless there is a documented, deliberate compatibility exception.
- Example:
- Bad:
```python
with op.batch_alter_table("dataset_keyword_tables") as batch_op:
batch_op.add_column(
sa.Column(
"data_source_type",
sa.String(255),
server_default=sa.text("'database'::character varying"),
nullable=False,
)
)
```
- Good:
```python
def _is_pg(conn) -> bool:
return conn.dialect.name == "postgresql"
conn = op.get_bind()
default_expr = sa.text("'database'::character varying") if _is_pg(conn) else sa.text("'database'")
with op.batch_alter_table("dataset_keyword_tables") as batch_op:
batch_op.add_column(
sa.Column("data_source_type", sa.String(255), server_default=default_expr, nullable=False)
)
```
@@ -1,61 +0,0 @@
# Rule Catalog - Repositories Abstraction
## Scope
- Covers: when to reuse existing repository abstractions, when to introduce new repositories, and how to preserve dependency direction between service/core and infrastructure implementations.
- Does NOT cover: SQLAlchemy session lifecycle and query-shape specifics (handled by `sqlalchemy-rule.md`), and table schema/migration design (handled by `db-schema-rule.md`).
## Rules
### Introduce repositories abstraction
- Category: maintainability
- Severity: suggestion
- Description: If a table/model already has a repository abstraction, all reads/writes/queries for that table should use the existing repository. If no repository exists, introduce one only when complexity justifies it, such as large/high-volume tables, repeated complex query logic, or likely storage-strategy variation.
- Suggested fix:
- First check `api/repositories`, `api/core/repositories`, and `api/extensions/*/repositories/` to verify whether the table/model already has a repository abstraction. If it exists, route all operations through it and add missing repository methods instead of bypassing it with ad-hoc SQLAlchemy access.
- If no repository exists, add one only when complexity warrants it (for example, repeated complex queries, large data domains, or multiple storage strategies), while preserving dependency direction (service/core depends on abstraction; infra provides implementation).
- Example:
- Bad:
```python
# Existing repository is ignored and service uses ad-hoc table queries.
class AppService:
def archive_app(self, app_id: str, tenant_id: str) -> None:
app = self.session.execute(
select(App).where(App.id == app_id, App.tenant_id == tenant_id)
).scalar_one()
app.archived = True
self.session.commit()
```
- Good:
```python
# Case A: Existing repository must be reused for all table operations.
class AppService:
def archive_app(self, app_id: str, tenant_id: str) -> None:
app = self.app_repo.get_by_id(app_id=app_id, tenant_id=tenant_id)
app.archived = True
self.app_repo.save(app)
# If the query is missing, extend the existing abstraction.
active_apps = self.app_repo.list_active_for_tenant(tenant_id=tenant_id)
```
- Bad:
```python
# No repository exists, but large-domain query logic is scattered in service code.
class ConversationService:
def list_recent_for_app(self, app_id: str, tenant_id: str, limit: int) -> list[Conversation]:
...
# many filters/joins/pagination variants duplicated across services
```
- Good:
```python
# Case B: Introduce repository for large/complex domains or storage variation.
class ConversationRepository(Protocol):
def list_recent_for_app(self, app_id: str, tenant_id: str, limit: int) -> list[Conversation]: ...
class SqlAlchemyConversationRepository:
def list_recent_for_app(self, app_id: str, tenant_id: str, limit: int) -> list[Conversation]:
...
class ConversationService:
def __init__(self, conversation_repo: ConversationRepository):
self.conversation_repo = conversation_repo
```
@@ -1,139 +0,0 @@
# Rule Catalog — SQLAlchemy Patterns
## Scope
- Covers: SQLAlchemy session and transaction lifecycle, query construction, tenant scoping, raw SQL boundaries, and write-path concurrency safeguards.
- Does NOT cover: table/model schema and migration design details (handled by `db-schema-rule.md`).
## Rules
### Use Session context manager with explicit transaction control behavior
- Category: best practices
- Severity: critical
- Description: Session and transaction lifecycle must be explicit and bounded on write paths. Missing commits can silently drop intended updates, while ad-hoc or long-lived transactions increase contention, lock duration, and deadlock risk.
- Suggested fix:
- Use **explicit `session.commit()`** after completing a related write unit.
- Or use **`session.begin()` context manager** for automatic commit/rollback on a scoped block.
- Keep transaction windows short: avoid network I/O, heavy computation, or unrelated work inside the transaction.
- Example:
- Bad:
```python
# Missing commit: write may never be persisted.
with Session(db.engine, expire_on_commit=False) as session:
run = session.get(WorkflowRun, run_id)
run.status = "cancelled"
# Long transaction: external I/O inside a DB transaction.
with Session(db.engine, expire_on_commit=False) as session, session.begin():
run = session.get(WorkflowRun, run_id)
run.status = "cancelled"
call_external_api()
```
- Good:
```python
# Option 1: explicit commit.
with Session(db.engine, expire_on_commit=False) as session:
run = session.get(WorkflowRun, run_id)
run.status = "cancelled"
session.commit()
# Option 2: scoped transaction with automatic commit/rollback.
with Session(db.engine, expire_on_commit=False) as session, session.begin():
run = session.get(WorkflowRun, run_id)
run.status = "cancelled"
# Keep non-DB work outside transaction scope.
call_external_api()
```
### Enforce tenant_id scoping on shared-resource queries
- Category: security
- Severity: critical
- Description: Reads and writes against shared tables must be scoped by `tenant_id` to prevent cross-tenant data leakage or corruption.
- Suggested fix: Add `tenant_id` predicate to all tenant-owned entity queries and propagate tenant context through service/repository interfaces.
- Example:
- Bad:
```python
stmt = select(Workflow).where(Workflow.id == workflow_id)
workflow = session.execute(stmt).scalar_one_or_none()
```
- Good:
```python
stmt = select(Workflow).where(
Workflow.id == workflow_id,
Workflow.tenant_id == tenant_id,
)
workflow = session.execute(stmt).scalar_one_or_none()
```
### Prefer SQLAlchemy expressions over raw SQL by default
- Category: maintainability
- Severity: suggestion
- Description: Raw SQL should be exceptional. ORM/Core expressions are easier to evolve, safer to compose, and more consistent with the codebase.
- Suggested fix: Rewrite straightforward raw SQL into SQLAlchemy `select/update/delete` expressions; keep raw SQL only when required by clear technical constraints.
- Example:
- Bad:
```python
row = session.execute(
text("SELECT * FROM workflows WHERE id = :id AND tenant_id = :tenant_id"),
{"id": workflow_id, "tenant_id": tenant_id},
).first()
```
- Good:
```python
stmt = select(Workflow).where(
Workflow.id == workflow_id,
Workflow.tenant_id == tenant_id,
)
row = session.execute(stmt).scalar_one_or_none()
```
### Protect write paths with concurrency safeguards
- Category: quality
- Severity: critical
- Description: Multi-writer paths without explicit concurrency control can silently overwrite data. Choose the safeguard based on contention level, lock scope, and throughput cost instead of defaulting to one strategy.
- Suggested fix:
- **Optimistic locking**: Use when contention is usually low and retries are acceptable. Add a version (or updated_at) guard in `WHERE` and treat `rowcount == 0` as a conflict.
- **Redis distributed lock**: Use when the critical section spans multiple steps/processes (or includes non-DB side effects) and you need cross-worker mutual exclusion.
- **SELECT ... FOR UPDATE**: Use when contention is high on the same rows and strict in-transaction serialization is required. Keep transactions short to reduce lock wait/deadlock risk.
- In all cases, scope by `tenant_id` and verify affected row counts for conditional writes.
- Example:
- Bad:
```python
# No tenant scope, no conflict detection, and no lock on a contested write path.
session.execute(update(WorkflowRun).where(WorkflowRun.id == run_id).values(status="cancelled"))
session.commit() # silently overwrites concurrent updates
```
- Good:
```python
# 1) Optimistic lock (low contention, retry on conflict)
result = session.execute(
update(WorkflowRun)
.where(
WorkflowRun.id == run_id,
WorkflowRun.tenant_id == tenant_id,
WorkflowRun.version == expected_version,
)
.values(status="cancelled", version=WorkflowRun.version + 1)
)
if result.rowcount == 0:
raise WorkflowStateConflictError("stale version, retry")
# 2) Redis distributed lock (cross-worker critical section)
lock_name = f"workflow_run_lock:{tenant_id}:{run_id}"
with redis_client.lock(lock_name, timeout=20):
session.execute(
update(WorkflowRun)
.where(WorkflowRun.id == run_id, WorkflowRun.tenant_id == tenant_id)
.values(status="cancelled")
)
session.commit()
# 3) Pessimistic lock with SELECT ... FOR UPDATE (high contention)
run = session.execute(
select(WorkflowRun)
.where(WorkflowRun.id == run_id, WorkflowRun.tenant_id == tenant_id)
.with_for_update()
).scalar_one()
run.status = "cancelled"
session.commit()
```
@@ -1,86 +0,0 @@
---
name: e2e-cucumber-playwright
description: Write, update, or review Dify end-to-end tests under `e2e/` that use Cucumber, Gherkin, and Playwright. Use when the task involves `.feature` files, `features/step-definitions/`, `features/support/`, `DifyWorld`, scenario tags, locator/assertion choices, or E2E testing best practices for this repository.
---
# Dify E2E Cucumber + Playwright
Use this skill for Dify's repository-level E2E suite in `e2e/`. Use [`e2e/AGENTS.md`](../../../e2e/AGENTS.md) as the canonical package guide for local architecture and conventions, then read any feature-scoped `AGENTS.md` that owns the target area. Apply Playwright/Cucumber best practices only where they fit the current suite.
## Scope
- Use this skill for `.feature` files, Cucumber step definitions, `DifyWorld`, hooks, tags, and E2E review work under `e2e/`.
- Do not use this skill for Vitest or React Testing Library work under `web/`; use `frontend-testing` instead.
- Do not use this skill for backend test or API review tasks under `api/`.
## Read Order
1. Read [`e2e/AGENTS.md`](../../../e2e/AGENTS.md) first.
2. Read only the files directly involved in the task:
- target `.feature` files under `e2e/features/`
- related step files under `e2e/features/step-definitions/`
- `e2e/features/support/hooks.ts` and `e2e/features/support/world.ts` when session lifecycle or shared state matters
- `e2e/scripts/run-cucumber.ts` and `e2e/cucumber.config.ts` when tags or execution flow matter
3. Read [`references/playwright-best-practices.md`](references/playwright-best-practices.md) only when locator, assertion, isolation, or waiting choices are involved.
4. Read [`references/cucumber-best-practices.md`](references/cucumber-best-practices.md) only when scenario wording, step granularity, tags, or expression design are involved.
5. Re-check official Playwright or Cucumber docs with the available documentation tools before introducing a new framework pattern.
Keep this skill focused on Cucumber, Playwright, and package-level E2E guidance. Put feature-specific conventions in the owning feature's `AGENTS.md` instead of adding them here.
## Local Rules
- `e2e/` uses Cucumber for scenarios and Playwright as the browser layer.
- `DifyWorld` is the per-scenario context object. Type `this` as `DifyWorld` and use `async function`, not arrow functions.
- Keep glue organized by capability under `e2e/features/step-definitions/`; use `common/` only for broadly reusable steps.
- Browser session behavior comes from `features/support/hooks.ts`:
- default: authenticated session with shared storage state
- `@unauthenticated`: clean browser context
- `@authenticated`: readability/selective-run tag only unless implementation changes
- `@fresh`: only for `e2e:full*` flows
- Do not import Playwright Test runner patterns that bypass the current Cucumber + `DifyWorld` architecture unless the task is explicitly about changing that architecture.
## Workflow
1. Rebuild local context.
- Inspect the target feature area.
- Reuse an existing step when wording and behavior already match.
- Add a new step only for a genuinely new user action or assertion.
- Before adding several similar steps, scan the target capability for an existing domain noun that can be parameterized without hiding behavior.
- Keep edits close to the current capability folder unless the step is broadly reusable.
2. Write behavior-first scenarios.
- Describe user-observable behavior, not DOM mechanics.
- Keep each scenario focused on one workflow or outcome.
- Keep scenarios independent and re-runnable.
3. Write step definitions in the local style.
- Keep one step to one user-visible action or one assertion.
- Prefer Cucumber Expressions such as `{string}` and `{int}`.
- Use a bounded regex only when the accepted values are a small explicit domain set and Cucumber Expressions would make the Gherkin less natural.
- Do not create one-off steps for each case variant when the same domain action or outcome applies to named surfaces, modes, or resources.
- Scope locators to stable containers when the page has repeated elements.
- Avoid page-object layers or extra helper abstractions unless repeated complexity clearly justifies them.
4. Use Playwright in the local style.
- Prefer user-facing locators: `getByRole`, `getByLabel`, `getByPlaceholder`, `getByText`, then `getByTestId` for explicit contracts.
- Use web-first `expect(...)` assertions.
- Do not use `waitForTimeout`, manual polling, or raw visibility checks when a locator action or retrying assertion already expresses the behavior.
- Use `expect.poll` for API persistence, backend eventual consistency, captured browser events, or other non-DOM state; prefer locator assertions for DOM readiness and visible UI state.
- If a product element has real user-facing semantics but no accessible name, prefer fixing that accessible contract over adding a test id.
5. Validate narrowly.
- Run the narrowest tagged scenario or flow that exercises the change.
- Run `vpr lint --fix --quiet` from the repository root and `pnpm -C e2e type-check`.
- Broaden verification only when the change affects hooks, tags, setup, or shared step semantics.
## Review Checklist
- Does the scenario describe behavior rather than implementation?
- Does it fit the current session model, tags, and `DifyWorld` usage?
- Should an existing step be reused instead of adding a new one?
- Are locators user-facing and assertions web-first?
- Does the change introduce hidden coupling across scenarios, tags, or instance state?
- Does it document or implement behavior that differs from the real hooks or configuration?
Lead findings with correctness, flake risk, and architecture drift.
## References
- [`references/playwright-best-practices.md`](references/playwright-best-practices.md)
- [`references/cucumber-best-practices.md`](references/cucumber-best-practices.md)
@@ -1,4 +0,0 @@
interface:
display_name: "E2E Cucumber + Playwright"
short_description: "Write and review Dify E2E scenarios."
default_prompt: "Use $e2e-cucumber-playwright to write or review a Dify E2E scenario under e2e/."
@@ -1,98 +0,0 @@
# Cucumber Best Practices For Dify E2E
Use this reference when writing or reviewing Gherkin scenarios, step definitions, parameter expressions, and step reuse in Dify's `e2e/` suite.
Official sources:
- https://cucumber.io/docs/guides/10-minute-tutorial/
- https://cucumber.io/docs/cucumber/step-definitions/
- https://cucumber.io/docs/cucumber/cucumber-expressions/
## What Matters Most
### 1. Treat scenarios as executable specifications
Cucumber scenarios should describe examples of behavior, not test implementation recipes.
Apply it like this:
- write what the user does and what should happen
- avoid UI-internal wording such as selector details, DOM structure, or component names
- keep language concrete enough that the scenario reads like living documentation
### 2. Keep scenarios focused
A scenario should usually prove one workflow or business outcome. If a scenario wanders across several unrelated behaviors, split it.
In Dify's suite, this means:
- one capability-focused scenario per feature path
- no long setup chains when existing bootstrap or reusable steps already cover them
- no hidden dependency on another scenario's side effects
### 3. Reuse steps, but only when behavior really matches
Good reuse reduces duplication. Bad reuse hides meaning.
Prefer reuse when:
- the user action is genuinely the same
- the expected outcome is genuinely the same
- the wording stays natural across features
- the parameter is a real product domain value such as a named surface, mode, resource, or status
Write a new step when:
- the behavior is materially different
- reusing the old wording would make the scenario misleading
- a supposedly generic step would become an implementation-detail wrapper
Do not optimize for a low step count by making vague steps. Optimize for a small set of truthful, domain-owned steps.
### 4. Prefer Cucumber Expressions
Use Cucumber Expressions for parameters unless regex is clearly necessary.
Common examples:
- `{string}` for labels, names, and visible text
- `{int}` for counts
- `{float}` for decimal values
- `{word}` only when the value is truly a single token
Keep expressions readable. If a step needs complicated parsing logic, first ask whether the scenario wording should be simpler.
Use regex for a bounded natural-language alternative only when it keeps Gherkin readable, for example `/(Web app|Backend service API)/`. Avoid broad regexes that accept unowned language.
### 5. Keep step definitions thin and meaningful
Step definitions are glue between Gherkin and automation, not a second abstraction language.
For Dify:
- type `this` as `DifyWorld`
- use `async function`
- keep each step to one user-visible action or assertion
- rely on `DifyWorld` and existing support code for shared context
- avoid leaking cross-scenario state
### 6. Use tags intentionally
Tags should communicate run scope or session semantics, not become ad hoc metadata.
In Dify's current suite:
- capability tags group related scenarios
- `@unauthenticated` changes session behavior
- `@authenticated` is descriptive/selective, not a behavior switch by itself
- `@fresh` belongs to reset/full-install flows only
If a proposed tag implies behavior, verify that hooks or runner configuration actually implement it.
## Review Questions
- Does the scenario read like a real example of product behavior?
- Are the steps behavior-oriented instead of implementation-oriented?
- Is a reused step still truthful in this feature?
- Is a new tag documenting real behavior, or inventing semantics that the suite does not implement?
- Would a new reader understand the outcome without opening the step-definition file?
@@ -1,99 +0,0 @@
# Playwright Best Practices For Dify E2E
Use this reference when writing or reviewing locator, assertion, isolation, or synchronization logic for Dify's Cucumber-based E2E suite.
Official sources:
- https://playwright.dev/docs/best-practices
- https://playwright.dev/docs/locators
- https://playwright.dev/docs/test-assertions
- https://playwright.dev/docs/browser-contexts
## What Matters Most
### 1. Keep scenarios isolated
Playwright's model is built around clean browser contexts so one test does not leak into another. In Dify's suite, that principle maps to per-scenario session setup in `features/support/hooks.ts` and `DifyWorld`.
Apply it like this:
- do not depend on another scenario having run first
- do not persist ad hoc scenario state outside `DifyWorld`
- do not couple ordinary scenarios to `@fresh` behavior
- when a flow needs special auth/session semantics, express that through the existing tag model or explicit hook changes
### 2. Prefer user-facing locators
Playwright recommends built-in locators that reflect what users perceive on the page.
Preferred order in this repository:
1. `getByRole`
2. `getByLabel`
3. `getByPlaceholder`
4. `getByText`
5. `getByTestId` when an explicit test contract is the most stable option
Avoid raw CSS/XPath selectors unless no stable user-facing contract exists and adding one is not practical.
Also remember:
- repeated content usually needs scoping to a stable container
- exact text matching is often too brittle when role/name or label already exists
- `getByTestId` is acceptable when semantics are weak but the contract is intentional
- when a real UI region, card, status, or icon lacks an accessible name, prefer adding that semantic contract in product code before falling back to `getByTestId`
### 3. Use web-first assertions
Playwright assertions auto-wait and retry. Prefer them over manual state inspection.
Prefer:
- `await expect(page).toHaveURL(...)`
- `await expect(locator).toBeVisible()`
- `await expect(locator).toBeHidden()`
- `await expect(locator).toBeEnabled()`
- `await expect(locator).toHaveText(...)`
Avoid:
- `expect(await locator.isVisible()).toBe(true)`
- custom polling loops for DOM state
- `waitForTimeout` as synchronization
If a condition genuinely needs custom retry logic, use Playwright's polling/assertion tools deliberately and keep that choice local and explicit.
Use `expect.poll` for non-DOM truth such as API state, backend eventual consistency, generated resources, or captured browser events. For DOM state, use locator assertions so Playwright can apply actionability and web-first retry semantics.
### 4. Let actions wait for actionability
Locator actions already wait for the element to be actionable. Do not preface every click/fill with extra timing logic unless the action needs a specific visible/ready assertion for clarity.
Good pattern:
- assert a meaningful visible state when that is part of the behavior
- then click/fill/select via locator APIs
Bad pattern:
- stack arbitrary waits before every action
- wait on unstable implementation details instead of the visible state the user cares about
### 5. Match debugging to the current suite
Playwright's wider ecosystem supports traces and rich debugging tools. Dify's current suite already captures:
- full-page screenshots
- page HTML
- console errors
- page errors
Use the existing artifact flow by default. If a task is specifically about improving diagnostics, confirm the change fits the current Cucumber architecture before importing broader Playwright tooling.
## Review Questions
- Would this locator survive DOM refactors that do not change user-visible behavior?
- Is this assertion using Playwright's retrying semantics?
- Is any explicit wait masking a real readiness problem?
- Does this code preserve per-scenario isolation?
- Is a new abstraction really needed, or does it bypass the existing `DifyWorld` + step-definition model?
@@ -1,94 +0,0 @@
---
name: frontend-code-review
description: Review Dify frontend code for correctness, accessibility, component design, dify-ui usage, data/query boundaries, performance, and tests. Trigger for `.tsx`, `.ts`, `.js`, UI, React, Next.js, pending-change, or focused frontend review requests.
---
# Frontend Code Review
## When To Use
Use this skill when the user asks to review, audit, analyze, or sanity-check frontend code under `web/`, `packages/dify-ui/`, or frontend-adjacent TypeScript files.
Supported modes:
- **Pending-change review**: inspect staged and working-tree changes.
- **File-focused review**: inspect explicitly named files or paths.
- **Diff/snippet review**: review pasted diffs or snippets using best-effort references.
Do not use this skill for backend-only code under `api/`; use `backend-code-review` instead.
## Required Context
Before reviewing, read the relevant local contracts:
- `web/AGENTS.md` for Dify frontend workflow, overlays, design tokens, state, and tests.
- `packages/dify-ui/README.md` and `packages/dify-ui/AGENTS.md` when code uses or changes `@langgenius/dify-ui/*`.
- `web/docs/overlay.md` when reviewing dialogs, drawers, popovers, tooltips, menus, selects, comboboxes, or other floating UI.
- `web/docs/test.md` and the `frontend-testing` skill when reviewing tests or testability.
- `karpathy-guidelines` for scope control and focused, verifiable changes.
- `how-to-write-component` when reviewing React component structure, ownership, effects, query/mutation contracts, or memoization.
For any UI, UX, or accessibility review, fetch the latest Web Interface Guidelines before finalizing findings. Treat them as a required baseline, not the complete source of accessibility truth:
```text
https://raw.githubusercontent.com/vercel-labs/web-interface-guidelines/main/command.md
```
If the review depends on a current framework, SDK, browser API, or accessibility behavior and local code does not settle it, check the current official docs first. For browser compatibility, deprecation, or behavior-sensitive frontend APIs, verify MDN or the relevant standard.
## Rule Packs
Apply every relevant rule pack:
- [references/accessibility-ui.md](references/accessibility-ui.md) — accessibility, semantic HTML, focus, forms, keyboard, disabled states, copy, and long-content behavior. Combines Web Interface Guidelines with Dify UI, Base UI, MDN, and local primitive contracts.
- [references/dify-ui.md](references/dify-ui.md) — Dify UI primitive usage, Base UI semantics, overlays, forms, tokens, radius mapping, and primitive boundaries.
- [references/component-architecture.md](references/component-architecture.md) — component ownership, props, state, effects, exports, wrappers, and feature organization.
- [references/data-query-contracts.md](references/data-query-contracts.md) — generated contracts, TanStack Query, mutations, workspace/auth/SSR boundaries, URL/local storage state.
- [references/performance.md](references/performance.md) — React/Next performance review rules from Vercel guidance, scoped to real risk.
- [references/testing.md](references/testing.md) — frontend test review rules.
- [references/dify-invariants.md](references/dify-invariants.md) — stable Dify-specific runtime invariants that generic React/a11y rules will not catch.
- [references/code-quality.md](references/code-quality.md) — general TypeScript, styling, naming, and maintainability rules.
## Review Process
1. Identify the review scope. For pending changes, inspect `git diff --stat`, `git diff`, and staged diff if relevant. For file-focused reviews, stay within the named files unless a referenced owner/contract must be read.
2. Read code around the changed lines and the owning module. Do not review by isolated snippets when nearby ownership, labels, query inputs, or overlay structure decide correctness.
3. Check user-visible regressions first: accessibility, broken interaction, auth/permission leaks, query/hydration errors, data loss, navigation mistakes, and impossible states.
4. Then check maintainability and performance: ownership, effects, wrappers, memoization, bundle/waterfall risks, tests, and design-system drift.
5. Report only actionable findings. Do not list speculative risks, style preferences, or broad refactors unless they are directly tied to a reproducible issue in scope.
## Severity
- **P0**: security/privacy/auth leak, data loss, production crash, inaccessible critical flow, or broken primary workflow.
- **P1**: user-visible regression, hydration/SSR failure, invalid API/query contract, broken keyboard/focus behavior, or serious design-system/a11y violation.
- **P2**: maintainability or performance issue likely to cause bugs, duplicated state, incorrect ownership, missing tests for risky behavior, or non-critical a11y issue.
- **P3**: minor cleanup with clear value. Omit unless the user asked for a thorough audit.
## Output Format
Lead with findings, ordered by severity. Use this structure:
```markdown
## Findings
- [P1] Short issue title
File: `path/to/file.tsx:123`
Why it matters and how to reproduce or reason about it.
Suggested fix: concrete fix direction.
## Open Questions
- Question or assumption, if any.
## Summary
Brief secondary context. Mention tests not run or residual risk.
```
Rules:
- If there are no findings, say `No issues found.` and mention any test gaps or residual risk.
- Always include file and line when available.
- Keep findings concrete and reproducible.
- Do not include praise sections by default.
- Do not ask to apply fixes unless the user explicitly wants review plus implementation.
@@ -1,109 +0,0 @@
# Accessibility And UI Rules
Accessibility findings are first-class review findings. Treat broken keyboard access, missing accessible names, focus loss, and unreachable popup content as correctness bugs, not polish.
Before finalizing UI or accessibility findings, fetch the latest Web Interface Guidelines as a required baseline:
```text
https://raw.githubusercontent.com/vercel-labs/web-interface-guidelines/main/command.md
```
Do not treat that document as the complete accessibility rule set. Combine it with:
- `packages/dify-ui/README.md`, `packages/dify-ui/AGENTS.md`, and the relevant primitive implementation when code uses `@langgenius/dify-ui/*`.
- Base UI docs and local `.d.ts` contracts when primitive semantics, focus target, labels, or popup reachability are unclear.
- MDN or relevant WAI-ARIA/browser standards when behavior, compatibility, or deprecation status matters.
- The current feature's product semantics, because an accessible primitive can still be used in an inaccessible workflow.
## Semantic HTML
Flag:
- Clickable `div` or `span` used for actions.
- Router navigation implemented with button or `onClick` when a `Link` / `<a>` is the real semantic element.
- Icon-only buttons without `aria-label` or `aria-labelledby`.
- Decorative icons missing `aria-hidden="true"`.
- Images without `alt`; use `alt=""` only when truly decorative.
- Heading levels that skip hierarchy in page-level content.
Prefer semantic HTML before ARIA.
## Keyboard And Focus
Flag:
- Interactive elements without visible `focus-visible` treatment.
- `outline-none` / `outline-hidden` without an equivalent focus-visible ring or state.
- Custom interactive elements missing keyboard handling.
- Focus trapped, lost, or sent to the wrong surface after dialog/popover/menu close.
- Focus ring applied to the wrong DOM node. Verify the actual focus target, especially with Base UI controls such as Slider.
Use `focus-visible` for keyboard focus. Use `focus-within` or `has-[:focus-visible]` when the visual wrapper is not the focused element.
## Forms
Flag:
- Inputs, selects, switches, checkboxes, radios, comboboxes, or sliders without a label relationship.
- Missing stable `name` on form fields that submit or validate.
- Incorrect input `type`, `inputMode`, `autoComplete`, or `spellCheck` for email, token, URL, number, search, code, or username fields.
- Labels that are not clickable.
- Submit buttons disabled before a request starts, preventing normal submit behavior.
- Non-submit buttons inside forms missing `type="button"`.
- Errors not associated with fields or not reachable by screen readers.
- Error recovery that does not focus or expose the first invalid field.
- `onPaste` blocking paste.
- Placeholder text used as the only label.
- Password managers accidentally triggered on non-auth fields because autocomplete is missing or wrong.
Prefer visible labels. If visible surrounding text already labels the control, use a visually hidden label or a precise `aria-label`.
## Disabled, Loading, And Async States
Flag:
- Loading state without `aria-busy`, `role="status"`, or another accessible update path when it changes user interaction.
- Spinner or decorative loading icon exposed to screen readers.
- Disabled controls that hide the reason users cannot proceed.
- `aria-disabled` used without manually blocking click, Space, and Enter.
- Toasts, inline validation, or async status changes that are not announced when users need the update to continue.
- Icon-only loading/error affordances without text or accessible status where the state matters.
Use native `disabled` when the control must not be interactive. Use `aria-disabled` only when the element must remain focusable and the code handles all blocked interactions.
For repeated shared disabled reasons, prefer a visible group message or badge plus native disabled controls. Use per-control popover/info only when the reason is item-specific.
## Overlays And Popup Reachability
Flag:
- Tooltip used for long, structured, interactive, or unique information.
- Tooltip content required to understand or complete a flow.
- PreviewCard content that touch or screen-reader users cannot reach through the trigger's click destination.
- Popover/dialog/menu triggers without accessible names.
- Popup content without title/description where the primitive requires them.
Use Popover for explanatory content, rich help, and infotips. Use Tooltip only as a short visual label for a trigger that already has an accessible name.
## Long Content And Layout
Flag:
- Text in flex/grid children without `min-w-0` when it can overflow.
- Names, labels, file names, model names, workspace names, or user content lacking `truncate`, `line-clamp`, or `break-words`.
- Right-side icons, badges, checks, or actions that shrink before the text area.
- Empty arrays or empty strings rendering broken layout instead of an empty state.
- Button, tab, badge, chip, menu item, or card text that can overlap sibling controls at common viewport widths.
The usual Dify layout chain is: container has width constraints, text region uses `min-w-0 flex-1 truncate`, adornments use `shrink-0`.
## Motion, Images, And Copy
Flag:
- `transition-all`.
- Animations that do not respect reduced motion.
- Layout-affecting animation where transform/opacity would work.
- Images without dimensions.
- Loading copy using `...` instead of `…`.
- Hardcoded dates, times, numbers, or currency formats instead of `Intl.*`.
@@ -1,68 +0,0 @@
# Code Quality Rules
## Scope Control
Flag changes that expand beyond the requested feature or review scope:
- Repo-wide cleanup mixed into a targeted fix.
- Compatibility exports, aliases, shims, or wrapper layers added without an explicit migration requirement.
- Shared abstractions created before there is stable cross-feature reuse.
- Business components moved into generic shared locations without a clear ownership boundary.
## TypeScript
Flag:
- `any` or broad `Record<string, any>` where generated/API types or local domain types exist.
- Re-declared API shapes instead of importing generated or returned types.
- Weak route/query param typing that leaks `string | string[] | undefined` deep into components.
- Runtime wrappers added only to satisfy TypeScript when a narrower type boundary would preserve the existing runtime shape.
Prefer:
- Explicit domain names that match the API contract.
- Type narrowing at route/API boundaries.
- Small conversion helpers colocated with the component that needs them.
## Styling
Flag:
- New CSS modules or ad hoc CSS when Tailwind utilities and Dify tokens cover the need.
- Component-level plain `.css` files or component CSS imported through `globals.css`; use scoped `*.module.css` only when Tailwind and component variants cannot express the style.
- Generic color utilities where Dify semantic tokens exist.
- Hardcoded magic class values for colors, spacing, radius, shadow, z-index, or typography when Dify tokens, component variants, or documented radius mappings exist.
- `!` important modifiers or important CSS overrides without a narrow, documented reason.
- Manual string concatenation, template strings, array `.join(' ')`, or custom ternaries for conditional or multi-line classes.
- JS conditional class branches for primitive visual states already exposed by Dify UI/Base UI `data-*` selectors.
- Incoming `className` placed before default classes in `cn(...)`, preventing call-site overrides.
- Arbitrary z-index or one-off layering fixes on overlays.
Use:
- `cn(...)` from the local package or utility already used by the file.
- Dify semantic tokens and Tailwind v4 utilities.
- Existing component variants before one-off class forks.
- Primitive selectors such as `data-disabled:*`, `data-checked:*`, `data-highlighted:*`, `group-data-*`, `peer-data-*`, and `has-[:focus-visible]` before adding React state or boolean props solely for styling.
- Component-level variants, semantic tokens, and normal cascade/order before `!` overrides. Use `!` only for a contained compatibility override that cannot be expressed through the component API or local selector structure.
## Imports
Flag:
- Barrel imports from `@langgenius/dify-ui`; consumers must use subpath exports.
- New overlay imports from legacy `@/app/components/base/modal`, `dialog`, or `drawer`.
- Cross-feature imports that bypass explicit top-level public files.
- Direct imports from generated/internal implementation files when a feature contract already exposes the intended surface.
## Copy And i18n
Flag:
- User-facing hardcoded strings in `web/`.
- Added or renamed i18n keys that are not present in every supported locale file for the touched namespace.
- Translation namespace drift, especially using unrelated module namespaces for local feature copy.
- Generic button labels like `Continue` where the action is specific.
- Error messages that state only the failure and not the next step.
Use feature-local translation keys by default. Alias only when crossing namespaces. `pnpm i18n:check --file <name>` should pass for any touched translation namespace.
@@ -1,89 +0,0 @@
# Component Architecture Rules
Use these rules for React component structure, ownership, state, props, effects, and module organization.
## Ownership
Flag:
- State, query, mutation, or handlers hoisted above the lowest component that actually uses them.
- Parent components owning row/item actions that do not coordinate a workflow.
- Prop drilling through multiple pass-through layers.
- A page/tab-level section component becoming the data owner without needing a shared snapshot or shared loading/error/empty UI.
- Feature code promoted to shared only because it appears once or might be reused later.
Accept repeated TanStack Query calls in siblings when each component independently consumes the data. Cache deduplication is not a reason to hoist by itself.
## Component Boundaries
Flag:
- React component files over 300 lines when the file mixes multiple responsibilities that can be split into focused colocated components, hooks, or utilities.
- Shallow wrappers that only rename props or hide the real primitive.
- Extra DOM wrappers that do not provide layout, semantics, accessibility, state ownership, or library integration.
- Dialog/dropdown/popover hidden surfaces that obscure the parent flow when they should be extracted into a small local component.
- Business forms, menu bodies, or one-off helpers moved away from their owner without reuse or semantic value.
Prefer colocated components split by actual data and state needs.
## Bad Component Design Patterns
Flag:
- Refactors of existing navigation, sidebar, dropdown, webapp list, or app-switching UI that do not preserve behavior-sensitive interactions such as expand/collapse arrows, hover persistence, pin/delete controls, routing, keyboard/focus handling, or open-state ownership.
- Components that mix data fetching, mutation side effects, popup state, form validation, layout, and row rendering without a clear owner.
- Generic components with many boolean props that encode one feature's workflow.
- A shared component that imports feature-specific copy, routes, or API contracts.
- A feature component that accepts pre-rendered fragments only to avoid placing ownership correctly.
- A child component that receives both raw server data and separately derived flags for the same concept.
- A wrapper that changes accessible semantics of the primitive it wraps.
- A component that exposes controlled props but still keeps a competing private state for the same value.
- A component that cannot render empty, loading, or missing optional API fields without caller-side preprocessing.
When existing components already own interaction logic, prefer reusing or extending them. If a refactor is necessary, preserve the old interaction contract and add or update focused tests for changed behavior.
## Props And Types
Flag:
- `React.FC` / `FC`.
- Default exports outside framework-required files.
- Named `Props` types for trivial one-off props where inline typing is clearer.
- Props named by UI implementation instead of domain/API role.
- API data converted too early or under a generic name that breaks traceability.
- Callers duplicating fallback checks that the lowest rendering component already handles.
Prefer top-level `function` declarations for components and module helpers. Use arrow functions for callbacks and local lambdas.
## Effects
Flag effects that:
- Transform props/state for rendering.
- Copy one state value into another representing the same concept.
- Handle user actions that belong in event handlers.
- Reset state from props when a keyed reset, stable ID, or render-time derivation would work.
- Fetch data that belongs in framework APIs or TanStack Query.
If an effect remains, it must synchronize with a named external system: browser API, subscription, timer, analytics-on-visibility, non-React widget, or imperative DOM integration.
## State Modeling
Flag:
- Storing derived booleans, disabled flags, default tabs, or loading labels that can be calculated from current query/feature state.
- Local state used to fake server data or generated contract fields.
- UI state persisted to localStorage when it is live app state.
- Feature-local mock shells wired to unrelated existing APIs before the real API is confirmed.
Prefer render-time derivation. Keep true local state for user choices, transient input, controlled popups, and feature UI state that has no server source.
## Navigation
Flag:
- Imperative router navigation for ordinary links.
- Button semantics used for navigation.
- Navigation state hidden in component state when URL state is required for shareable filters, tabs, or pagination.
Use `Link` for normal navigation. Use router APIs for mutation success, guarded redirects, command flows, or form submission side effects.
@@ -1,74 +0,0 @@
# Data, Query, And Contract Rules
Use these rules for generated contracts, TanStack Query, mutations, auth/SSR boundaries, URL state, and client persistence.
## Generated Contracts
Flag:
- New legacy service/helper wrappers around generated `queryOptions()` or `mutationOptions()`.
- Continuing to use deprecated contract operations when a ready generated contract exists.
- Assuming a generated file means an operation is ready without checking deprecated markers, schema shape, and the actual UI consumer.
- Re-declaring API DTOs in components.
- Adding compatibility layers instead of migrating the pointed line and deleting the old layer.
Use `web/contract/*` as the API shape source of truth. Follow existing `{ params, query?, body? }` input shape.
## Queries
Flag:
- `enabled` used to hide missing required input instead of `input: skipToken`.
- Fake fallback IDs or placeholder inputs used to force a query to run.
- Query results copied into local state for rendering.
- Shared query behavior such as invalidation, stale defaults, or retry rules reimplemented at call sites.
- `prefetchQuery` treated as a hard gate or as returning data/errors to the caller.
Use `useQuery(consoleQuery.xxx.queryOptions(...))` or `useQuery(marketplaceQuery.xxx.queryOptions(...))` directly unless a feature hook performs real orchestration.
## Mutations
Flag:
- Deprecated `useInvalid` or `useReset`.
- `mutateAsync` used without a need for Promise semantics.
- Awaited mutations without `try/catch`.
- Components owning shared cache invalidation that belongs in query defaults.
- Optimistic updates that do not match current list/detail ownership.
Use generated `mutationOptions()` directly when possible. Put shared cache behavior in `createTanstackQueryUtils(...experimental_defaults...)`.
## SSR, Auth, And Route Boundaries
Flag:
- Request-time auth, setup, workspace role, or tenant decisions moved into static `next.config redirects()`.
- Dynamic role gates depending on `workspaces.current` implemented as static path redirects.
- Authorization logic depending on soft `prefetchQuery`.
- Removing a client fallback before server API unavailable behavior is defined.
- Global placeholder query contracts introduced to solve a route-local Suspense issue.
- Branding-sensitive UI reading placeholder defaults without checking pending/placeholder state.
Separate hard gates from soft prefetches. `fetchQuery` can be a server decision boundary; `prefetchQuery` is cache warmup.
## Workspace And Tenant
Flag:
- Treating workspace switch as ordinary CRUD invalidation when the current app flow performs server switch plus full reload.
- Query keys that omit workspace/tenant identity when the query truly varies by workspace and no full reload boundary applies.
- Mixing `workspace_id` and `tenant_id` without tracing the current backend/API contract.
Current Dify workspace switch should be reviewed as a tenant cache boundary first.
## URL State And Local Storage
Flag:
- Shareable filters, tabs, pagination, selected panels, or search state hidden only in component state.
- One-shot navigation signals modeled as subscribed persistent state.
- Live app state stored in localStorage.
- Direct `window.localStorage`, `globalThis.localStorage`, or raw storage calls in app code.
- High-frequency interaction state persisted on every change instead of on commit/settle.
Use URL state for shareable UI state, feature/Jotai/store state for live UI state, and `@/hooks/use-local-storage` only for low-frequency client-only preferences, dismissed notices, and UI defaults.
@@ -1,22 +0,0 @@
# Dify Invariants
Use these stable Dify-specific runtime rules in addition to the generic review packs.
This file is not a place for active feature notes. Do not add rules for one branch, one PR, or a short-lived product decision such as a specific agent-v2, plugin, model-provider, or onboarding task. Keep a rule here only when all of these are true:
- It is a stable Dify runtime invariant.
- Generic React, TypeScript, accessibility, dify-ui, query, or performance rules would not catch it.
- The failure mode is concrete enough to produce a file-line review finding.
- The rule is likely to remain valid across normal feature work.
## Workflow Nodes And RAG Pipe
Flag:
- Node components under `web/app/components/workflow/nodes/[nodeName]/node.tsx` importing workflow store hooks that are unavailable in RAG Pipe template rendering.
- Node UI relying on provider context that is not mounted in every rendering surface.
- Store reads in render where React Flow `useNodes` / `useEdges` provide the actual node/edge source.
Known failure mode: workflow node components can also render while creating a RAG Pipe from a template. In that context there may be no workflowStore provider, causing a blank screen.
Prefer React Flow hooks for node/edge UI consumption. Use store APIs only where the provider is guaranteed and the code path is workflow-only.
@@ -1,141 +0,0 @@
# Dify UI Rules
Use these rules whenever a review touches `packages/dify-ui/` or code consuming `@langgenius/dify-ui/*`.
Before finalizing findings for those files, read the current local docs that apply:
- `packages/dify-ui/README.md`
- `packages/dify-ui/AGENTS.md`
- `web/docs/overlay.md` for floating UI
- `packages/dify-ui/src/<primitive>/index.tsx` for the primitive being changed or consumed
## Package Boundary
Flag in `packages/dify-ui`:
- Imports from `web/`.
- Dependencies on Next.js, i18n, ky, Jotai, Zustand, TanStack Query, oRPC, or business APIs.
- Business-specific component behavior that belongs in `web/`.
- Multiple unrelated primitives in one component folder.
`packages/dify-ui` is a primitive layer: Base UI headless components + `cva` + `cn` + Dify design tokens.
## Imports And Exports
Flag:
- Consumer imports from `@langgenius/dify-ui` without a subpath.
- Missing `package.json#exports` entry for a new primitive.
- Internal package imports using workspace subpaths instead of relative paths.
- Exported props using internal-only types that consumers cannot import from the component subpath.
- Canonical primitive boundaries or their associated public types using a redundant `Root` suffix when no higher-level convenience component exists in the same subpath.
Consumers use subpath exports such as `@langgenius/dify-ui/button`.
Canonical boundaries use the primitive name and matching public types (`Select` / `SelectProps`). Keep `Root` only to distinguish a low-level anatomy root from a higher-level convenience component (`CheckboxRoot` / `Checkbox`); implementation aliases should still show their Base UI source (`BaseSelect.Root.Props`).
## Props And State
Flag:
- Flattened props where related values need a discriminated union, such as `value` / `defaultValue`, `multiple` / `value`, or `clearable` / `onChange`.
- React state used only to mirror Base UI state for class names.
- JavaScript conditional class logic for visual states that the Dify UI/Base UI primitive already exposes through `data-*` attributes or CSS variables.
- Controlled props added when uncontrolled DOM state or CSS variables would be enough.
- Thin wrappers that rename Base UI parts without adding semantics.
- Generic Base UI selection primitives wrapped without preserving their value generics, such as `Select.Root<Value, Multiple>`, `RadioGroup<Value>`, or `Radio.Root<Value>`.
- Shared select/radio option components that type selected values as `string` while callers pass enums, unions, booleans, numbers, objects, or nullable placeholder values.
Prefer Base UI/Dify UI data attributes and CSS variables for visual state: `data-open`, `data-checked`, `data-disabled`, `data-highlighted`, `data-popup-open`, `group-data-*`, `peer-data-*`, `has-[:focus-visible]`, and primitive CSS variables such as anchor width or transform origin. Use JS conditional classes for product/business state that the primitive does not expose.
For non-string `Select` and `RadioGroup` values, prefer explicit domain generics at the root and at child value carriers. JSX children do not inherit the parent generic, so `RadioGroup<PromptMode>` should compose with `Radio<PromptMode>`, `RadioItem<PromptMode>`, or option values from a typed collection. For `Select`, prefer the Base UI `items` collection pattern for typed value-to-label rendering, and flag string coercion helpers used only to recover display labels.
## Forms
Flag:
- Form-like UI using unrelated `Input` and `Button` pieces without a submit boundary.
- Text-like fields not composed through `Field`, `FieldLabel`, and `FieldControl` when using Dify UI form semantics.
- Select fields using `FieldLabel` instead of `SelectLabel`.
- Slider fields using a generic label instead of `SliderLabel`.
- Checkbox/radio groups missing `Fieldset` and `FieldsetLegend`.
- Field errors or descriptions rendered without `FieldDescription` / `FieldError` relationships.
`Form` is the submit boundary. Dify UI form primitives are not a form state-management framework; business validation and schema-driven behavior belong in `web/`.
## Overlay Contract
Flag:
- Legacy web overlay imports in new or modified code.
- Manual portals around Dify UI overlay primitives.
- Call-site `z-*` overrides on overlays.
- Missing root `isolation: isolate` assumptions when debugging overlay stacking.
- Repeated backdrop, z-index, or portal chrome at call sites.
- Tooltip used for infotips, long text, or interactive content.
All Dify UI body-portalled overlays use `z-50`. Toast uses `z-60`. DOM order handles stacking between overlays.
## Primitive Selection
Flag:
- `Tabs` used for simple mode/filter/view selection where `SegmentedControl` is the semantic primitive.
- `SegmentedControl` used where `tablist` / `tabpanel` semantics are required.
- `Select` used for searchable or free-form input.
- `Combobox` used for unrestricted search text where no selected option is remembered.
- `Autocomplete` used for closed-list selection.
- Tooltip or PreviewCard used for content that must be reachable on touch or by screen readers.
Use:
- `Autocomplete` for free-form text with optional suggestions.
- `Combobox` for searchable selected values from a collection.
- `Select` for closed, scannable option sets.
- `Popover` for infotips, help text, rich content, or interactions.
## Bad Usage Patterns To Flag
Flag:
- Manually recreating UI behavior or chrome already owned by `@langgenius/dify-ui/*` or `web/app/components/base/*`, such as buttons, inputs, toggle groups, popovers, dropdown menus, alert dialogs, switches, avatars, scroll areas, toasts, borders, focus states, disabled states, segmented controls, or existing feature components.
- Styling a raw Base UI primitive directly in `web/` when a Dify UI primitive exists.
- Wrapping a Dify UI primitive in a feature component that hides its label, error, disabled, or focus contract.
- Replacing a semantic primitive with a generic `div` plus classes to match a screenshot.
- Using `Tooltip` because it is visually convenient when the content is actually help text or needs touch access.
- Adding a `z-*` override to make a child popup appear over a parent dialog.
- Adding a new app-level wrapper around Dialog, Drawer, Popover, Select, or Combobox that repeats portal/backdrop/positioner logic.
- Using dify-ui `Input` as a drop-in replacement for legacy inputs that include search, clear, copy, unit, localized placeholder, or number normalization behavior.
- Building a form row from loose text and controls instead of the matching Field/Form primitives.
- Adding component state only to style `data-open`, `data-checked`, `data-disabled`, or highlighted states that Base UI already exposes.
- Passing booleans down only so children can toggle classes already expressible with primitive `data-*` selectors.
## Tokens, Radius, And Styling
Flag:
- `radius-*` class names.
- Custom Tailwind `borderRadius` extension for Figma radius values.
- Generic colors where semantic Dify tokens exist.
- Hardcoded design values where Dify tokens, component variants, or documented Figma radius mappings exist.
- `!` important modifiers used to fight primitive styles instead of fixing the variant, selector, or component composition.
- Manual class strings that duplicate primitive variants.
- `min-w-(--anchor-width)` on picker popups when it defeats viewport clamping.
Use the Figma radius mapping from `packages/dify-ui/AGENTS.md`; for example `--radius/sm` maps to `rounded-md`, and `--radius/md` maps to `rounded-lg`.
Use `!` only for a tightly scoped compatibility override after confirming the primitive API, data attributes, and selector structure cannot express the state.
## Focus Details
Flag focus rings attached to the wrong element. For example, Base UI `Slider.Thumb` focuses an internal `input[type=range]`, so the visible thumb wrapper needs `has-[:focus-visible]` rather than direct wrapper `focus-visible`.
## Custom SVG Icons
Flag:
- New generated React icon components or JSON files under `web/app/components/base/icons/src/...` for custom SVG icons.
- Custom SVG icons consumed outside the Tailwind `i-custom-*` icon class pipeline.
- Generated `packages/iconify-collections/custom-*/icons.json` diffs where unrelated existing icons lost or changed intrinsic `width` or `height`.
New custom SVG icons belong in `packages/iconify-collections/assets/...`. Regenerate with `pnpm --filter @dify/iconify-collections generate`, validate with `pnpm --filter @dify/iconify-collections check:dimensions`, and consume the generated icon with Tailwind `i-custom-*` classes.
@@ -1,78 +0,0 @@
# Performance Rules
Review performance only where there is realistic impact. Do not request `memo`, `useMemo`, `useCallback`, virtualization, or caching as style preferences.
## Async Waterfalls
Flag:
- Awaiting remote feature flags or fetches before checking cheap synchronous conditions.
- Sequential awaits for independent operations.
- API routes or server components starting requests late when they could start early.
- Nested per-item fetches running serially when each item can fetch in parallel.
- Suspense boundaries that force the whole page to wait when a lower boundary could stream or isolate loading.
Prefer `Promise.all` for independent work and branch-local awaits for conditionally needed data.
## Bundle Size
Flag:
- Barrel imports from heavy libraries or `@langgenius/dify-ui`.
- Dynamic paths that prevent static trace analysis.
- Heavy components loaded eagerly when hidden behind a dialog, tab, command, or feature activation.
- Analytics, logging, editor, visualization, or third-party SDK code loaded before it is needed.
- Feature-local optional modules imported at top level only for rare flows.
Use direct imports and `next/dynamic` where the user-visible path benefits.
## Server Rendering
Flag:
- Request-specific mutable state stored at module scope in SSR/RSC paths.
- Large duplicate data serialized across RSC/client boundaries.
- Static I/O repeated per request when it could be hoisted safely.
- Cross-request cache without a bounded invalidation strategy.
- Server actions lacking API-route-equivalent auth checks.
Use request-scoped deduplication such as `React.cache()` when repeated server reads in one request are the problem.
## Re-rendering
Flag:
- Effects or subscriptions reading broad state when a derived boolean or narrower selector is enough.
- Components defined inside components.
- Derived rendering state stored in state/effects.
- Non-primitive default props recreated for memoized children.
- Expensive work recalculated on every render where it affects real interaction cost.
- High-frequency transient values stored in state when refs or CSS variables would avoid render loops.
Do not flag simple primitive expressions wrapped or not wrapped in `useMemo`; prefer no memo for simple work.
Require stable object/array/function identity only when:
- The child is memoized and identity affects renders.
- The value is an effect/query dependency.
- A library API requires stable references.
- Profiling or local behavior shows avoidable re-rendering.
## DOM, Lists, And Rendering
Flag:
- Layout reads in render (`getBoundingClientRect`, `offset*`, `scrollTop`).
- Interleaved DOM reads/writes that can cause layout thrashing.
- Large lists rendering without virtualization, pagination, or `content-visibility`.
- SVG/animation code animating expensive properties when transform/opacity would work.
- `transition-all`.
- Long-running non-critical browser work performed immediately instead of idle/deferred scheduling.
## React Flow
For workflow React Flow components, keep this Dify-specific rule:
- UI consumption should use React Flow hooks such as `useNodes` / `useEdges`.
- Callback-only reads or mutations can use `useStoreApi`.
- Node components under `web/app/components/workflow/nodes/[nodeName]/node.tsx` must not depend on workflow stores that are absent in RAG Pipe template rendering.
@@ -1,36 +0,0 @@
# Testing Review Rules
`web/docs/test.md` is the canonical frontend testing policy. Use this file only to translate that policy into review findings.
## Request Missing Tests When Risk Justifies Them
Flag missing coverage when a change alters a reachable contract such as:
- User interaction, navigation, form submission, validation, or permissions.
- Query or mutation behavior, URL state, persistence, or one-shot signals.
- Loading, error, empty, and recovery states that users can encounter.
- Accessibility-critical labels, keyboard flow, focus, disabled state, or overlay behavior.
- A regression-prone business rule or bug fix that can be reproduced through a public boundary.
Do not request tests for mechanical changes, pass-through wrappers, implementation details, or visual-only styling unless they affect behavior. Low coverage alone is not a finding.
## Flag Low-Value or Fragile Tests
Flag tests that:
- Assert internal state, refs, hook usage, effect dependencies, private DOM structure, or cosmetic classes.
- Exist only to render a component, exercise a prop, or cover generic invalid inputs without a product scenario.
- Mock away the behavior under review or use mocks that do not match the public contract.
- Add production `data-testid` attributes where semantic markup would work.
- Use fake timers without timer behavior, leave async work unawaited, or leak shared state.
- Duplicate a contract already protected at a more useful owner boundary.
## Review the Test Boundary
- Prefer semantic queries and accessible names.
- Prefer real feature components when integration semantics matter.
- Allow intentional child or provider mocks when setup would dominate the test and that boundary is covered independently.
- Do not accept semantically inaccurate mocks of Dify UI or legacy base primitives.
- Require a real-browser or visual verification plan when `happy-dom` cannot represent the risk.
Treat test quality, determinism, and regression value as the review criteria. Do not use test count or coverage percentage as a proxy for quality.
-36
View File
@@ -1,36 +0,0 @@
---
name: frontend-testing
description: Write, update, or review Dify frontend tests using Vitest and Testing Library. Trigger for frontend specs, test coverage requests, regressions, testability, or testing strategy under web/ or packages/dify-ui/.
---
# Dify Frontend Testing
Use this skill for Vitest work under `web/` and `packages/dify-ui/`. Do not use it for Python tests or Cucumber/Playwright tests under `e2e/`.
## Required Source
Before writing, changing, or reviewing frontend tests, read `web/docs/test.md` completely. It is the single source of truth. This skill defines the execution workflow and must not add requirements that conflict with or duplicate that guide.
## Workflow
1. Read the source, its behavior owner, nearby specs, and relevant public dependencies.
1. Identify whether the contract belongs in `web/`, Dify UI Browser Mode, or a styled Storybook test.
1. Apply the canonical guide to decide whether a test is needed and choose its boundary.
1. For a behavior change or bug fix, write or identify the failing scenario first when practical.
1. Implement one coherent scenario at a time and run the focused spec before expanding scope.
1. Finish with the affected suite and relevant repository checks.
1. Report what behavior was verified and any risk that still requires browser, visual, or end-to-end validation.
When reviewing existing tests, recommend deleting low-value tests as readily as adding missing behavior coverage.
Run focused tests from the owning workspace:
```bash
# web/
vp test run path/to/spec-or-directory
# packages/dify-ui/
vp test run --project unit src/path/to/spec
```
For styled Dify UI behavior, run `vp test --project storybook --run`. Run broader checks only after the focused behavior passes.
@@ -1,144 +0,0 @@
---
name: how-to-write-component
description: Use when writing, refactoring, or reviewing React/TypeScript components in Dify web, especially decisions about component ownership, props/types, URL/query state, Jotai state, async state, generated API contracts, queries/mutations, overlays, effects, navigation, performance, and empty states.
---
# How To Write A Component
Use this as the component decision guide for Dify web. Existing code is reference material, not automatic precedent; if touched code violates these rules, adapt it and fix equivalent patterns in the same feature branch.
## First Decisions
| Question | Default | Promote or extract only when |
| --- | --- | --- |
| Where should code live? | Keep it local to the feature workflow, route, or owner. | Multiple verticals need the same stable primitive. |
| How should route/tab folders be named? | Match the current route segment, tab name, or user-visible surface. | Keep a historical or broader parent only when it still owns multiple surfaces. |
| Who owns state, data, and handlers? | The lowest component that uses them. | A parent coordinates shared loading, errors, empty UI, selection, submission, navigation, or one consistent snapshot. |
| Should this become Jotai state? | Keep synchronous UI/form state in component or DOM state. | Siblings need one source of truth, the value drives atoms, or scoped workflow state must survive hidden/unmounted steps. |
| Should URL state enter Jotai? | Let Next.js route params and `nuqs` own URL state and updates. | Query atoms or shared derived atoms need a read-only bridge hydrated at the route/surface boundary. |
| Should this query/mutation become an atom? | Use TanStack Query hooks at the lowest owner. | It reads atom state, feeds derived atoms, or participates in shared Jotai workflow orchestration. |
| Should this be a helper/wrapper? | Prefer direct readable code at the use site. | The name captures a stable domain rule or the wrapper owns real behavior, validation, state, error handling, or semantics. |
| Where should a hotkey live? | Keep a single-owner hotkey constant in its component. | Multiple production files share one command, or the feature owns a real command registry with shared metadata and behavior. |
| Is an Effect needed? | No. Derive during render or handle the user action in the event handler. | It synchronizes with an external system such as browser APIs, subscriptions, timers, analytics, or imperative DOM/non-React widgets. |
## Core Defaults
- Search before adding UI, hooks, helpers, query utilities, or styling patterns. Reuse existing base components, feature components, hooks, utilities, and design styles when they fit.
- Follow Dify's CSS-first Tailwind v4 contract from `packages/dify-ui/README.md` and `packages/dify-ui/AGENTS.md`. Prefer design-system tokens, utilities, and radius mappings over generic Tailwind choices.
- Preserve visible keyboard focus states on the final focusable element. Prefer styled `@langgenius/dify-ui/*` controls when available, because components such as `Button` and form/control primitives carry the standard Dify UI `focus-visible` styling. Do not assume every Dify UI export provides visual focus styles: headless anatomy parts and direct Base UI re-exports such as dialog/popover/tooltip/drawer triggers usually only provide behavior and semantics. When using native `button` / `a`, custom trigger `render` props, clickable rows, icon buttons, menu-like items, or direct trigger parts, verify the rendered focusable element has a visible focus state. If it does not, add the standard Dify UI focus style: `outline-hidden focus-visible:ring-2 focus-visible:ring-state-accent-solid`. Do not hide outlines without an equivalent visible `focus-visible` indicator. Component-specific focus styles should follow an existing styled primitive pattern or a concrete design constraint, not a new ad hoc style.
- Group feature code by workflow, route, or ownership area with route-aligned names: components, hooks, local types, query helpers, atoms, constants, tests, and small utilities should live near the code that changes with them.
- For each feature module, keep a module-local `README.md` as a boundary note. Start with the module name, a brief one-sentence description, then split dependencies into `Internal Modules` and `External Modules` sections; keep both sections and write `None.` when one category is empty. `Internal Modules` lists modules inside the same overall feature using paths from that feature root, such as `shared/domain/runtime-status`; `External Modules` lists project modules outside the feature using paths from the web root without a `web/` prefix, such as `app/components/base/skeleton`. Omit npm packages, workspace package dependencies, and whitelisted plumbing modules. Do not copy caller-relative import paths into the README.
- Module README whitelist: `@/service/client`, `@/next/*`.
- Keep source/default selection, validation, dirty checks, and payload shaping close to the workflow that owns submit behavior. Do not hide flow-specific priority order, fallback behavior, or submit semantics in generic utilities.
- Prefer direct conditionals for small branch-specific decisions, especially form source selection and request payload assembly.
- Loading states for page sections, cards, lists, tables, forms, and drawers should be skeletons scoped to the content being loaded. Use spinners only for small inline busy indicators.
## Layout And Ownership
- State-heavy wizards, drawers, modals, and secondary workflows can be a small feature surface: an entry file, one feature-local state file when Jotai is actually needed, and shallow `ui/` owners that match real visual regions.
- The entry file handles route integration, provider wiring, close behavior, and surface mounting. The composition owner handles high-level workflow branching. The closest visual owner handles section branching.
- When a page or tab maps to a route segment, name its feature folder after that route/tab surface instead of a stale parent grouping. Remove misleading intermediate folders when only one surface remains.
- When a tab folder grows into several independent sections or action areas, split the first level by product/visual owners. Keep the root for the entry component and cross-owner state, colocate tests with the owner folder, and put truly shared local UI under a specifically named `components/` file.
- Repeated TanStack query calls in sibling components are acceptable when each component independently consumes the data; TanStack Query deduplicates and shares cache.
- Pass stable domain identity across boundaries. Do not forward derived presentation state when the receiver can derive it from its own data source.
- A component that owns a visual surface should also own data access, loading, empty, and error states for content rendered inside it unless a parent truly coordinates that state.
- Avoid prop drilling. One pass-through layer is acceptable; repeated forwarding means ownership should move down or into feature-scoped Jotai UI state. Keep server/cache state in Query and API flow.
- Do not replace prop drilling with one large view-model hook threaded through section props. Move each hook, query, derived value, and handler to the concrete section that consumes it.
- Keep callbacks in a parent only for workflow coordination such as form submission, shared selection, batch behavior, or navigation. Otherwise let the child, menu, or row own the action.
## Feature-Scoped Jotai
- A Jotai-backed feature has one feature-local state file for shared primitive atoms, query atoms, derived atoms, write-only actions, mutation atoms, submission orchestration, provider exports, and optional scope configuration.
- Keep component-owned synchronous UI state local even inside Jotai features: dialog open flags, menus/popovers, confirmations, field drafts, and selected local options usually belong in component state.
- Use uncontrolled `@langgenius/dify-ui/form` and `@langgenius/dify-ui/field` controls for edit/create forms whose fields are read only at submit time. Initialize query-backed defaults with `defaultValue` and keyed remounts.
- Promote form state to atoms only when another component must react to in-progress values, a draft must survive unmount/remount in the scoped workflow, or multiple steps share the same editable draft before submit.
- Treat `useParams`, route args, and `nuqs` query state as framework-owned state. When atom logic needs those values, hydrate primitive atoms at the route or surface boundary, such as with `useHydrateAtoms(..., { dangerouslyForceHydrate: true })`; keep URL updates in the route/query-state APIs instead of write atoms.
- Within a route-owned feature, choose one source for route identity. If route params are bridged into feature atoms, use that bridge consistently for route-derived queries and actions instead of also threading the same route id through page, tab, and section props.
- For async work tied to atom state, use `atomWithQuery` or `atomWithMutation`; write atoms should update only the inputs that drive those atoms. This applies to pure frontend async work as well as network requests, so do not hand-roll loading/error/in-flight state with `useState` or `useRef` for atom-orchestrated async behavior. For component-owned remote work, use `useQuery` or `useMutation` directly.
- `jotai-tanstack-query` query atoms do not support TanStack Query tracked properties. A component that reads `useAtomValue(queryAtom)` subscribes to the whole query result, even if it only accesses `data`, `isLoading`, or `isError`. Export field-specific derived atoms and have components read the exact fields they render; use `selectAtom(queryAtom, result => result.field)` for query-result fields so unchanged selections do not notify subscribers. Keep direct `useAtomValue(queryAtom)` only when the component or hook genuinely needs the full observer result.
- Row-local async state belongs to the row owner unless it participates in a shared Jotai workflow or needs atom-scoped reset semantics.
- Leave query and mutation atoms unscoped so they keep shared QueryClient cache and invalidation behavior. Scope resettable primitives and explicit hydration tuples; scope a derived atom only when every dependency should be private to that surface.
- For scoped primitives that are always hydrated by `ScopeProvider`, prefer `atomWithLazy<T>(() => { throw new Error(...) })` when consumers should see a non-null type.
- Order state files by dependency graph: types/constants, primitives, query atoms, query-data derived atoms, business/readiness derived atoms, write actions, mutation atoms, submission orchestration, provider exports.
- Name derived atoms as business facts and write atoms as user or workflow commands. Components should read or write the exact atom they need with `useAtomValue` or `useSetAtom`.
- Menu/dialog `open` state usually stays local, but a scoped atom is acceptable when a composed menu plus secondary surface would otherwise pass confusing `open`/`onClose` props through unrelated layers. Scope that primitive with the surface instance so reset behavior stays local.
- Keep independent dialog lifecycles separate. Avoid one discriminated "current action dialog" atom when dialogs have separate open state, loading guards, or reset behavior.
## Components, Props, And Types
- Type component signatures directly; do not use `FC` or `React.FC`.
- Prefer `function` for top-level components and module helpers. Use arrow functions for local callbacks, handlers, and lambda-style APIs.
- Prefer named exports. Use default exports only where the framework requires them, such as Next.js route files.
- Avoid barrel files that only re-export secondary owners. `index.tsx` is acceptable for a route/tab entry component; import header controls, switches, sections, and row owners from their concrete owner files.
- Type simple one-off props inline. Use a named `Props` type only when reused, exported, complex, or clearer.
- Use API-generated or API-returned types at component boundaries. Keep small UI conversion helpers and one-off UI extensions beside the component that needs them.
- Preserve domain value types for selection components. Do not widen enum, union, boolean, numeric, object, or nullable select/radio values to `string`; keep wrappers and option value carriers typed from their feature option collection.
- Avoid `common.tsx` buckets for shared UI. Use a feature-local `components/` folder with concrete filenames that describe the shared role.
- Do not create type aliases that only rename another type. Use aliases only for real UI concepts, refinements, or reusable local contracts.
- Name values by their domain role and backend API contract, especially persistent IDs and route params. Normalize framework or route params at the boundary.
- Put fallback and invariant checks in the lowest component that already handles that state. Do not extract helpers whose only behavior is hiding missing display data.
## Keyboard Shortcuts
- Distinguish application commands from local keyboard semantics before choosing an API. Use `@tanstack/react-hotkeys` for application commands. Keep menu navigation, dialog Escape handling owned by a primitive, editor commands, and other widget-scoped ARIA interactions in their local component or primitive.
- Use `useHotkey` or `useHotkeys` for registered commands. For a command intentionally owned by an existing `onKeyDown`, use `matchesKeyboardEvent` instead of hand-written `metaKey` / `ctrlKey` parsing or a second global listener.
- Define a reusable string command with `satisfies Hotkey` and an object-form command with `satisfies RawHotkey`. Reserve `RegisterableHotkey` for API boundaries that intentionally accept either form. A one-time inline literal passed directly to TanStack is already type-checked; extract it when registration, display, metadata, or another production consumer needs the same source.
- Keep registered hotkeys distinct from held keys and display-only accelerators. Use `IndividualKey` with `useKeyHold` for held-key interactions, and use an explicitly named `displayKey` for local widget accelerators that are not registered `Hotkey` values.
- Keep registration and keycap/menu display derived from one canonical command. Do not maintain a hotkey string beside a separate `['Mod', ...]` display array.
- Keep a single-owner command constant in its owning component. Create a feature-local `hotkeys.ts` only when multiple production files consume the same command. Keep a dedicated definitions/registry module when a feature owns a real command system with IDs, metadata, alternate bindings, and centralized registration. Tests do not count as another production owner, and file-name uniformity alone is not a reason to extract.
- Make scope and availability explicit. Use `enabled` for business or surface lifecycle, `ignoreInputs` for whether input-like elements may trigger the command, and `target` when the command belongs to a concrete DOM subtree. Global application commands may use the document target; inline editors and composed overlays should prefer the actual editor or Base UI Popup ref when that owner is exposed.
- Put a scoped ref on the real behavior owner. Do not add a wrapper DOM element solely to obtain a hotkey target. If a shared overlay convenience component hides the Popup ref, either rely on its modal lifecycle/focus boundary when that is sufficient or design the primitive API separately; do not create a fake owner at the call site.
- Set `preventDefault` and `stopPropagation` according to the existing product behavior and browser interaction. Do not silently accept TanStack defaults when migrating from another listener if that changes typing, submission, or propagation semantics.
- Test observable command behavior, disabled/input/target scope, and the shared registration/display contract at the owning feature boundary. Prefer partial mocks that retain TanStack formatting and matching behavior when a registration boundary must be isolated.
## Generated API And Nullable Data
- Treat generated contracts as authoritative at API, query, mutation, cache, and service boundaries. For enterprise APIs, use `packages/contracts/generated/enterprise/*`.
- Do not hand-write DTO mirrors, widen generated fields/enums, or add parallel frontend enum/status layers unless they model product state not represented by the API.
- Use generated enum objects and union types directly in props, comparisons, status logic, and i18n keys. Presentation-only tone maps should be keyed by generated enums.
- Normalize or coerce only at real boundaries: user-entered forms, search, URL/query params, file names, DOM IDs, or legacy adapters.
- Do not coerce nullable or optional API strings to `''` in query, derived model, or payload-building code. Keep `null` or `undefined` until the final boundary requiring a string.
- Do not use `value || undefined` for mutation fields where `''` means "clear this value". Trim or normalize at the form boundary, then preserve intentional empty strings.
- Prefer nullable-tolerant render props for API-returned rows. Narrow only where a real value is required, such as mutation params, route hrefs, select values, query input, or required React keys.
- Build required values in the same branch that proves them, using `flatMap`, a local loop, or an early return. Avoid truthiness guards, `filter(Boolean)`, `filter(item => item.id)`, and `!` after filters.
- Use conditional spreads or explicit pushes for conditional array items instead of `undefined` placeholders followed by narrowing filters.
- Empty collection fallbacks are for not-yet-loaded query data or genuinely nullable collections at the owning render boundary, not for hiding required API fields.
## Queries And Mutations
- Keep `web/contract/*` as the API shape source of truth and follow the `{ params, query?, body? }` input shape.
- Consume generated queries with `useQuery(consoleQuery.xxx.queryOptions(...))` or `useQuery(marketplaceQuery.xxx.queryOptions(...))`.
- If a generated query input comes from an atom, including a route-identity bridge atom, keep the query in `atomWithQuery`; do not unwrap the atom in a component just to call `useQuery`.
- Consume owner-local mutations with `useMutation(consoleQuery.xxx.mutationOptions(...))` or `useMutation(marketplaceQuery.xxx.mutationOptions(...))` when pending/error state is not consumed by feature atoms.
- In `atomWithQuery`, `atomWithInfiniteQuery`, and `atomWithMutation`, return generated `queryOptions()`, `infiniteOptions()`, or `mutationOptions()` directly. Pass `enabled`, `retry`, `placeholderData`, `select`, and pagination options into the generated call instead of spreading options into a hand-built object.
- For generated oRPC options with missing required input, branch the whole input with `input: condition ? validInput : skipToken` and `enabled: Boolean(condition)`. Never place `skipToken` inside a nested placeholder payload or coerce required IDs to `''`.
- When prefetch and render use the same request, extract local query options or a query-options atom so `prefetchQuery` and `useQuery`/`atomWithQuery` share the exact options.
- For custom query or mutation functions, wrap options with TanStack `queryOptions(...)` or `mutationOptions(...)`.
- Do not extract generated `queryOptions(...)` into a helper solely to share input construction; extract only when prefetch/render must share exact options or the helper owns real domain behavior.
- Avoid pass-through hooks and thin `web/service/use-*` wrappers that only rename generated options. Keep feature hooks for real orchestration, workflow state, or shared domain behavior.
- Put shared cache behavior in `createTanstackQueryUtils(...experimental_defaults...)`. Component or atom callbacks may handle local toasts, closing dialogs, and navigation, but should not replace shared invalidation or patch shared server state locally.
- For overlays that may open heavier secondary content, prefetch from the trigger/menu open event with `queryClient.prefetchQuery(queryOptions)` when `onOpenChange` is available. Do not mount hidden subscribers just to warm cache.
- Do not use deprecated `useInvalid` or `useReset`.
- Prefer `mutate(...)`; use `mutateAsync(...)` only when Promise semantics are required, and wrap awaited calls in `try/catch`.
## Boundaries And Overlays
- Use the first level below a page or tab to organize independent page sections when it adds structure or the root folder becomes noisy. This layer is layout/semantic first, not automatically the data owner.
- Treat component names, semantic roles, and user- or design-marked visual regions as boundary constraints. Keep adjacent UI as a sibling owner or introduce a correctly named broader owner.
- Keep cohesive forms, menu bodies, and one-off helpers local unless they need their own state, reuse, or semantic boundary.
- Separate hidden secondary surfaces from the trigger's main flow. For dialogs, dropdowns, popovers, and similar branches, extract a small local component when hidden content would obscure the parent.
- Preserve composability by separating behavior ownership from placement ownership: an action can own trigger/open/menu content while the caller owns slots, offsets, and alignment.
- When a dialog, dropdown, or popover accepts controlled `open`, mount it unconditionally unless unmounting is required for performance or reset semantics. Use keyed scope or local state reset instead of `{open && <Surface />}` wrappers.
- When opening a dialog from a menu item, keep the menu and dialog as sibling surfaces. Let the menu command open the dialog, and mount the dialog outside menu popup content.
- For dialogs and alert dialogs, keep the root responsible for `open` wiring and put query/mutation hooks inside the content component when work should mount only after the overlay opens.
- Prefer uncontrolled overlay roots when the library can own open state. Use `onOpenChange` for side effects and CSS/data selectors for open-state styling.
- Avoid wrapper DOM unless it provides layout, semantics, accessibility, state ownership, or library integration. Avoid shallow wrappers, hook-to-props adapters, layout-only render props, children pass-through wrappers, and prop renaming unless they add real behavior or a real boundary.
## Effects, Navigation, And Performance
- Use Effects only to synchronize with external systems. Do not use Effects to transform props/state for rendering, handle user actions, copy state, reset state from props, or fetch data.
- For forms initialized from query data, prefer keyed remounts or surface-entry atom hydration over Effects that copy query data into form state.
- Prefer framework data APIs or TanStack Query for data fetching.
- Prefer `Link` for normal navigation. Use router APIs only for command-flow side effects such as mutation success, guarded redirects, or form submission.
- Before using `memo`, move changing state down to the smallest component that uses it. If state must wrap stable content, lift the stable content up and pass it as `children`.
- Avoid `memo`, `useMemo`, and `useCallback` unless there is a clear performance reason.
@@ -1,33 +0,0 @@
---
name: karpathy-guidelines
description: Lightweight coding guardrails for making focused, simple, and verifiable changes in this repo. Use for all coding work.
---
# Karpathy Guidelines
Use this skill whenever you touch code in this repository.
## Principles
- Keep the change small and directly tied to the user request.
- Prefer the simplest implementation that fits the existing codebase.
- Read the nearby code first, then match its patterns.
- Avoid unrelated refactors, broad rewrites, or style churn.
- Preserve existing behavior unless the user explicitly asked to change it.
- Treat regressions as a signal to narrow the change, not to add workaround layers.
## Workflow
1. Inspect the current implementation and tests around the change.
2. Make the smallest coherent edit.
3. Add or update focused tests when the behavior changes or the risk is non-trivial.
4. Run the narrowest relevant verification first.
5. Report exactly what was verified and anything left unverified.
## Review Checklist
- Does this change solve the stated problem without expanding scope?
- Did it preserve existing route/component/data-flow semantics?
- Are new abstractions justified by real complexity?
- Are tests focused on the behavior that could regress?
- Are unrelated files and generated artifacts left alone?
-15
View File
@@ -1,15 +0,0 @@
{
"hooks": {
"PreToolUse": [
{
"matcher": "Bash",
"hooks": [
{
"type": "command",
"command": "npx -y block-no-verify@1.1.1"
}
]
}
]
}
}
-1
View File
@@ -1 +0,0 @@
../../.agents/skills/backend-code-review
-1
View File
@@ -1 +0,0 @@
../../.agents/skills/component-refactoring
-1
View File
@@ -1 +0,0 @@
../../.agents/skills/e2e-cucumber-playwright
-1
View File
@@ -1 +0,0 @@
../../.agents/skills/frontend-code-review
-1
View File
@@ -1 +0,0 @@
../../.agents/skills/frontend-testing
-1
View File
@@ -1 +0,0 @@
../../.agents/skills/how-to-write-component
-1
View File
@@ -1 +0,0 @@
../../.agents/skills/karpathy-guidelines
-6
View File
@@ -1,6 +0,0 @@
[run]
omit =
api/conftest.py
api/tests/*
api/migrations/*
api/core/rag/datasource/vdb/*
+4 -3
View File
@@ -1,4 +1,5 @@
FROM mcr.microsoft.com/devcontainers/python:3.12-bookworm
FROM mcr.microsoft.com/devcontainers/python:3.12
RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \
&& apt-get -y install libgmp-dev libmpfr-dev libmpc-dev
# [Optional] Uncomment this section to install additional OS packages.
# RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \
# && apt-get -y install --no-install-recommends <your-package-list-here>
+3 -8
View File
@@ -1,26 +1,23 @@
# Development with devcontainer
This project includes a devcontainer configuration that allows you to open the project in a container with a fully configured development environment.
Both frontend and backend environments are initialized when the container is started.
## GitHub Codespaces
[![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/langgenius/dify)
you can simply click the button above to open this project in GitHub Codespaces.
For more info, check out the [GitHub documentation](https://docs.github.com/en/free-pro-team@latest/github/developing-online-with-codespaces/creating-a-codespace#creating-a-codespace).
## VS Code Dev Containers
## VS Code Dev Containers
[![Open in Dev Containers](https://img.shields.io/static/v1?label=Dev%20Containers&message=Open&color=blue&logo=visualstudiocode)](https://vscode.dev/redirect?url=vscode://ms-vscode-remote.remote-containers/cloneInVolume?url=https://github.com/langgenius/dify)
if you have VS Code installed, you can click the button above to open this project in VS Code Dev Containers.
You can learn more in the [Dev Containers documentation](https://code.visualstudio.com/docs/devcontainers/containers).
## Pros of Devcontainer
## Pros of Devcontainer
Unified Development Environment: By using devcontainers, you can ensure that all developers are developing in the same environment, reducing the occurrence of "it works on my machine" type of issues.
Quick Start: New developers can set up their development environment in a few simple steps, without spending a lot of time on environment configuration.
@@ -28,15 +25,13 @@ Quick Start: New developers can set up their development environment in a few si
Isolation: Devcontainers isolate your project from your host operating system, reducing the chance of OS updates or other application installations impacting the development environment.
## Cons of Devcontainer
Learning Curve: For developers unfamiliar with Docker and VS Code, using devcontainers may be somewhat complex.
Performance Impact: While usually minimal, programs running inside a devcontainer may be slightly slower than those running directly on the host.
## Troubleshooting
if you see such error message when you open this project in codespaces:
![Alt text](troubleshooting.png)
a simple workaround is change `/signin` endpoint into another one, then login with GitHub account and close the tab, then change it back to `/signin` endpoint. Then all things will be fine.
The reason is `signin` endpoint is not allowed in codespaces, details can be found [here](https://github.com/orgs/community/discussions/5204)
The reason is `signin` endpoint is not allowed in codespaces, details can be found [here](https://github.com/orgs/community/discussions/5204)
+9 -6
View File
@@ -2,19 +2,16 @@
// README at: https://github.com/devcontainers/templates/tree/main/src/anaconda
{
"name": "Python 3.12",
"build": {
"build": {
"context": "..",
"dockerfile": "Dockerfile"
},
"mounts": [
"source=dify-dev-tmp,target=/tmp,type=volume"
],
"features": {
"ghcr.io/devcontainers/features/node:1": {
"nodeGypDependencies": true,
"version": "lts"
},
"ghcr.io/devcontainers-extra/features/npm-package:1": {
"ghcr.io/devcontainers-contrib/features/npm-package:1": {
"package": "typescript",
"version": "latest"
},
@@ -37,13 +34,19 @@
},
"postStartCommand": "./.devcontainer/post_start_command.sh",
"postCreateCommand": "./.devcontainer/post_create_command.sh"
// Features to add to the dev container. More info: https://containers.dev/features.
// "features": {},
// Use 'forwardPorts' to make a list of ports inside the container available locally.
// "forwardPorts": [],
// Use 'postCreateCommand' to run commands after the container is created.
// "postCreateCommand": "python --version",
// Configure tool-specific properties.
// "customizations": {},
// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
}
// "remoteUser": "root"
}
+2 -2
View File
@@ -1,3 +1,3 @@
This file copied into the container along with environment.yml* from the parent
folder. This file is included to prevents the Dockerfile COPY instruction from
failing if no environment.yml is found.
folder. This file is included to prevents the Dockerfile COPY instruction from
failing if no environment.yml is found.
+7 -10
View File
@@ -1,16 +1,13 @@
#!/bin/bash
WORKSPACE_ROOT=$(pwd)
export COREPACK_ENABLE_DOWNLOAD_PROMPT=0
corepack enable
npm add -g pnpm@9.12.2
cd web && pnpm install
pipx install uv
pipx install poetry
echo "alias start-api=\"cd $WORKSPACE_ROOT/api && uv run python -m flask run --host 0.0.0.0 --port=5001 --debug\"" >> ~/.bashrc
echo "alias start-worker=\"cd $WORKSPACE_ROOT/api && uv run python -m celery -A app.celery worker -P threads -c 1 --loglevel INFO -Q dataset,dataset_summary,priority_dataset,priority_pipeline,pipeline,mail,ops_trace,app_deletion,plugin,workflow_storage,conversation,workflow,schedule_poller,schedule_executor,triggered_workflow_dispatcher,trigger_refresh_publisher,trigger_refresh_executor,retention\"" >> ~/.bashrc
echo "alias start-web=\"cd $WORKSPACE_ROOT/web && pnpm dev:inspect\"" >> ~/.bashrc
echo "alias start-web-prod=\"cd $WORKSPACE_ROOT/web && pnpm build && pnpm start\"" >> ~/.bashrc
echo "alias start-containers=\"cd $WORKSPACE_ROOT/docker && docker-compose -f docker-compose.middleware.yaml -p dify --env-file middleware.env up -d\"" >> ~/.bashrc
echo "alias stop-containers=\"cd $WORKSPACE_ROOT/docker && docker-compose -f docker-compose.middleware.yaml -p dify --env-file middleware.env down\"" >> ~/.bashrc
echo 'alias start-api="cd /workspaces/dify/api && poetry run python -m flask run --host 0.0.0.0 --port=5001 --debug"' >> ~/.bashrc
echo 'alias start-worker="cd /workspaces/dify/api && poetry run python -m celery -A app.celery worker -P gevent -c 1 --loglevel INFO -Q dataset,generation,mail,ops_trace,app_deletion"' >> ~/.bashrc
echo 'alias start-web="cd /workspaces/dify/web && pnpm dev"' >> ~/.bashrc
echo 'alias start-containers="cd /workspaces/dify/docker && docker-compose -f docker-compose.middleware.yaml -p dify up -d"' >> ~/.bashrc
echo 'alias stop-containers="cd /workspaces/dify/docker && docker-compose -f docker-compose.middleware.yaml -p dify down"' >> ~/.bashrc
source /home/vscode/.bashrc
+1 -1
View File
@@ -1,3 +1,3 @@
#!/bin/bash
cd api && uv sync
cd api && poetry install
-15
View File
@@ -1,15 +0,0 @@
**/node_modules
**/.pnpm-store
**/dist
**/.next
**/.turbo
**/.cache
**/__pycache__
**/*.pyc
**/.mypy_cache
**/.ruff_cache
.git
.github
*.md
!web/README.md
!api/README.md
-39
View File
@@ -1,39 +0,0 @@
# EditorConfig is awesome: https://EditorConfig.org
# top-most EditorConfig file
root = true
# Unix-style newlines with a newline ending every file
[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
[*.py]
indent_size = 4
indent_style = space
[*.{yml,yaml}]
indent_style = space
indent_size = 2
[*.toml]
indent_size = 4
indent_style = space
# Markdown and MDX are whitespace sensitive languages.
# Do not remove trailing spaces.
[*.{md,mdx}]
trim_trailing_whitespace = false
# Matches multiple files with brace expansion notation
# Set default charset
[*.{js,jsx,ts,tsx,mjs}]
indent_style = space
indent_size = 2
# Matches the exact files package.json
[package.json]
indent_style = space
indent_size = 2
-13
View File
@@ -1,13 +0,0 @@
have_fun: false
memory_config:
disabled: false
code_review:
disable: true
comment_severity_threshold: MEDIUM
max_review_comments: -1
pull_request_opened:
help: false
summary: false
code_review: false
include_drafts: false
ignore_patterns: []
+1 -5
View File
@@ -1,11 +1,7 @@
# Ensure that .sh scripts use LF as line separator, even if they are checked out
# to Windows(NTFS) file-system, by a user of Docker for Windows.
# to Windows(NTFS) file-system, by a user of Docker for Window.
# These .sh scripts will be run from the Container after `docker compose up -d`.
# If they appear to be CRLF style, Dash from the Container will fail to execute
# them.
*.sh text eol=lf
# Codegen output must stay byte-identical across platforms so
# `pnpm tree:check` in CI does not trip on CRLF rewrites.
*.generated.ts text eol=lf
-281
View File
@@ -1,281 +0,0 @@
# CODEOWNERS
# This file defines code ownership for the Dify project.
# Each line is a file pattern followed by one or more owners.
# Owners can be @username, @org/team-name, or email addresses.
# For more information, see: https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners
* @crazywoola @laipz8200
# Lint bulk suppression baselines.
/oxlint-suppressions.json
/eslint-suppressions.json
# CODEOWNERS file
/.github/CODEOWNERS @laipz8200 @crazywoola
# Agents
/.agents/skills/ @hyoban
# Packages
/packages/ @lyzno1
/packages/contracts/ @crazywoola @laipz8200
# Docs
/docs/ @crazywoola
# CLI
/cli/ @GareArc
/.github/workflows/cli-tests.yml @GareArc
# E2E
/e2e/ @lyzno1
# Backend (default owner, more specific rules below will override)
/api/ @QuantumGhost
# Backend - MCP
/api/core/mcp/ @Nov1c444
/api/core/entities/mcp_provider.py @Nov1c444
/api/services/tools/mcp_tools_manage_service.py @Nov1c444
/api/controllers/mcp/ @Nov1c444
/api/controllers/console/app/mcp_server.py @Nov1c444
# Backend - Tests
/api/tests/ @laipz8200 @QuantumGhost
/api/tests/**/*mcp* @Nov1c444
# Backend - Workflow - Engine (Core graph execution engine)
/api/core/workflow/graph_engine/ @laipz8200 @QuantumGhost
/api/core/workflow/runtime/ @laipz8200 @QuantumGhost
/api/core/workflow/graph/ @laipz8200 @QuantumGhost
/api/core/workflow/graph_events/ @laipz8200 @QuantumGhost
/api/core/workflow/node_events/ @laipz8200 @QuantumGhost
# Backend - Workflow - Nodes (Agent, Iteration, Loop, LLM)
/api/core/workflow/nodes/agent/ @Nov1c444
/api/core/workflow/nodes/iteration/ @Nov1c444
/api/core/workflow/nodes/loop/ @Nov1c444
/api/core/workflow/nodes/llm/ @Nov1c444
# Backend - RAG (Retrieval Augmented Generation)
/api/core/rag/ @JohnJyong
/api/services/rag_pipeline/ @JohnJyong
/api/services/dataset_service.py @JohnJyong
/api/services/knowledge_service.py @JohnJyong
/api/services/external_knowledge_service.py @JohnJyong
/api/services/hit_testing_service.py @JohnJyong
/api/services/metadata_service.py @JohnJyong
/api/services/vector_service.py @JohnJyong
/api/services/entities/knowledge_entities/ @JohnJyong
/api/services/entities/external_knowledge_entities/ @JohnJyong
/api/controllers/console/datasets/ @JohnJyong
/api/controllers/service_api/dataset/ @JohnJyong
/api/models/dataset.py @JohnJyong
/api/tasks/rag_pipeline/ @JohnJyong
/api/tasks/add_document_to_index_task.py @JohnJyong
/api/tasks/batch_clean_document_task.py @JohnJyong
/api/tasks/clean_document_task.py @JohnJyong
/api/tasks/clean_notion_document_task.py @JohnJyong
/api/tasks/document_indexing_task.py @JohnJyong
/api/tasks/document_indexing_sync_task.py @JohnJyong
/api/tasks/document_indexing_update_task.py @JohnJyong
/api/tasks/duplicate_document_indexing_task.py @JohnJyong
/api/tasks/recover_document_indexing_task.py @JohnJyong
/api/tasks/remove_document_from_index_task.py @JohnJyong
/api/tasks/retry_document_indexing_task.py @JohnJyong
/api/tasks/sync_website_document_indexing_task.py @JohnJyong
/api/tasks/batch_create_segment_to_index_task.py @JohnJyong
/api/tasks/create_segment_to_index_task.py @JohnJyong
/api/tasks/delete_segment_from_index_task.py @JohnJyong
/api/tasks/disable_segment_from_index_task.py @JohnJyong
/api/tasks/disable_segments_from_index_task.py @JohnJyong
/api/tasks/enable_segment_to_index_task.py @JohnJyong
/api/tasks/enable_segments_to_index_task.py @JohnJyong
/api/tasks/clean_dataset_task.py @JohnJyong
/api/tasks/deal_dataset_index_update_task.py @JohnJyong
/api/tasks/deal_dataset_vector_index_task.py @JohnJyong
# Backend - Plugins
/api/core/plugin/ @WH-2099
/api/services/plugin/ @WH-2099
/api/controllers/console/workspace/plugin.py @WH-2099
/api/controllers/inner_api/plugin/ @WH-2099
/api/tasks/process_tenant_plugin_autoupgrade_check_task.py @WH-2099
# Backend - Trigger/Schedule/Webhook
/api/controllers/trigger/ @CourTeous33
/api/controllers/console/app/workflow_trigger.py @CourTeous33
/api/controllers/console/workspace/trigger_providers.py @CourTeous33
/api/core/trigger/ @CourTeous33
/api/core/app/layers/trigger_post_layer.py @CourTeous33
/api/services/trigger/ @CourTeous33
/api/models/trigger.py @CourTeous33
/api/fields/workflow_trigger_fields.py @CourTeous33
/api/repositories/workflow_trigger_log_repository.py @CourTeous33
/api/repositories/sqlalchemy_workflow_trigger_log_repository.py @CourTeous33
/api/libs/schedule_utils.py @CourTeous33
/api/services/workflow/scheduler.py @CourTeous33
/api/schedule/trigger_provider_refresh_task.py @CourTeous33
/api/schedule/workflow_schedule_task.py @CourTeous33
/api/tasks/trigger_processing_tasks.py @CourTeous33
/api/tasks/trigger_subscription_refresh_tasks.py @CourTeous33
/api/tasks/workflow_schedule_tasks.py @CourTeous33
/api/tasks/workflow_cfs_scheduler/ @CourTeous33
/api/events/event_handlers/sync_plugin_trigger_when_app_created.py @CourTeous33
/api/events/event_handlers/update_app_triggers_when_app_published_workflow_updated.py @CourTeous33
/api/events/event_handlers/sync_workflow_schedule_when_app_published.py @CourTeous33
/api/events/event_handlers/sync_webhook_when_app_created.py @CourTeous33
# Backend - Async Workflow
/api/services/async_workflow_service.py @Mairuis
/api/tasks/async_workflow_tasks.py @Mairuis
# Backend - Billing
/api/services/billing_service.py @hj24 @zyssyz123
/api/controllers/console/billing/ @hj24 @zyssyz123
# Backend - Enterprise
/api/configs/enterprise/ @GarfieldDai @GareArc
/api/services/enterprise/ @GarfieldDai @GareArc
/api/services/feature_service.py @GarfieldDai @GareArc
/api/controllers/console/feature.py @GarfieldDai @GareArc
/api/controllers/web/feature.py @GarfieldDai @GareArc
# Backend - Database Migrations
/api/migrations/ @snakevash @laipz8200 @MRZHUH
# Backend - Vector DB Middleware
/api/configs/middleware/vdb/* @JohnJyong
# Frontend
/web/ @iamjoel
# Frontend - Platform and Features
/web/config/ @lyzno1
/web/contract/ @lyzno1
/web/env.ts @lyzno1
/web/features/ @lyzno1
/web/hooks/ @lyzno1
/web/scripts/gen-icons.mjs @lyzno1
# Frontend - Web Tests
/.github/workflows/web-tests.yml @iamjoel
# Frontend - App - Orchestration
/web/app/components/workflow/ @iamjoel @zxhlyh
/web/app/components/workflow-app/ @iamjoel @zxhlyh
/web/app/components/app/configuration/ @iamjoel @zxhlyh
/web/app/components/app/app-publisher/ @iamjoel @zxhlyh
# Frontend - WebApp - Chat
/web/app/components/base/chat/ @iamjoel @zxhlyh
# Frontend - WebApp - Completion
/web/app/components/share/text-generation/ @iamjoel @zxhlyh
# Frontend - App - List and Creation
/web/app/components/apps/ @JzoNgKVO @iamjoel
/web/app/components/app/create-app-dialog/ @JzoNgKVO @iamjoel
/web/app/components/app/create-app-modal/ @JzoNgKVO @iamjoel
/web/app/components/app/create-from-dsl-modal/ @JzoNgKVO @iamjoel
# Frontend - App - API Documentation
/web/app/components/develop/ @JzoNgKVO @iamjoel
/web/app/components/develop/template/*.mdx @JzoNgKVO @iamjoel @RiskeyL
# Frontend - App - Logs and Annotations
/web/app/components/app/workflow-log/ @JzoNgKVO @iamjoel
/web/app/components/app/log/ @JzoNgKVO @iamjoel
/web/app/components/app/log-annotation/ @JzoNgKVO @iamjoel
/web/app/components/app/annotation/ @JzoNgKVO @iamjoel
# Frontend - App - Monitoring
/web/app/(commonLayout)/app/(appDetailLayout)/\[appId\]/overview/ @JzoNgKVO @iamjoel
/web/app/components/app/overview/ @JzoNgKVO @iamjoel
# Frontend - App - Settings
/web/app/components/app-sidebar/ @JzoNgKVO @iamjoel
# Frontend - RAG - Hit Testing
/web/app/components/datasets/hit-testing/ @JzoNgKVO @iamjoel
# Frontend - RAG - List and Creation
/web/app/components/datasets/list/ @iamjoel @WTW0313
/web/app/components/datasets/create/ @iamjoel @WTW0313
/web/app/components/datasets/create-from-pipeline/ @iamjoel @WTW0313
/web/app/components/datasets/external-knowledge-base/ @iamjoel @WTW0313
# Frontend - RAG - Orchestration (general rule first, specific rules below override)
/web/app/components/rag-pipeline/ @iamjoel @WTW0313
/web/app/components/rag-pipeline/components/rag-pipeline-main.tsx @iamjoel @zxhlyh
/web/app/components/rag-pipeline/store/ @iamjoel @zxhlyh
# Frontend - RAG - Documents List
/web/app/components/datasets/documents/list.tsx @iamjoel @WTW0313
/web/app/components/datasets/documents/create-from-pipeline/ @iamjoel @WTW0313
# Frontend - RAG - Segments List
/web/app/components/datasets/documents/detail/ @iamjoel @WTW0313
# Frontend - RAG - Settings
/web/app/components/datasets/settings/ @iamjoel @WTW0313
# Frontend - Ecosystem - Plugins
/web/app/components/plugins/ @iamjoel @zhsama
# Frontend - Ecosystem - Tools
/web/app/components/tools/ @iamjoel @Yessenia-d
# Frontend - Ecosystem - MarketPlace
/web/app/components/plugins/marketplace/ @iamjoel @Yessenia-d
# Frontend - Login and Registration
/web/app/signin/ @douxc @iamjoel
/web/app/signup/ @douxc @iamjoel
/web/app/reset-password/ @douxc @iamjoel
/web/app/install/ @douxc @iamjoel
/web/app/init/ @douxc @iamjoel
/web/app/forgot-password/ @douxc @iamjoel
/web/app/account/ @douxc @iamjoel
# Frontend - Service Authentication
/web/service/base.ts @douxc @iamjoel
# Frontend - WebApp Authentication and Access Control
/web/app/(shareLayout)/components/ @douxc @iamjoel
/web/app/(shareLayout)/webapp-signin/ @douxc @iamjoel
/web/app/(shareLayout)/webapp-reset-password/ @douxc @iamjoel
/web/app/components/app/app-access-control/ @douxc @iamjoel
# Frontend - Explore Page
/web/app/components/explore/ @CodingOnStar @iamjoel
# Frontend - Personal Settings
/web/app/components/header/account-setting/ @CodingOnStar @iamjoel
/web/app/components/header/account-dropdown/ @CodingOnStar @iamjoel
# Frontend - Analytics
/web/app/components/base/ga/ @CodingOnStar @iamjoel
# Frontend - Base Components
/web/app/components/base/ @iamjoel @zxhlyh
# Frontend - Base Components Tests
/web/app/components/base/**/*.spec.tsx @hyoban @CodingOnStar
# Frontend - Utils and Hooks
/web/utils/classnames.ts @iamjoel @zxhlyh
/web/utils/time.ts @iamjoel @zxhlyh
/web/utils/format.ts @iamjoel @zxhlyh
/web/utils/clipboard.ts @iamjoel @zxhlyh
# Frontend - Billing and Education
/web/app/components/billing/ @iamjoel @zxhlyh
/web/app/education-apply/ @iamjoel @zxhlyh
# Frontend - Workspace
/web/app/components/header/account-dropdown/workplace-selector/ @iamjoel @zxhlyh
# Docker
/docker/* @laipz8200
+12 -10
View File
@@ -17,25 +17,27 @@ diverse, inclusive, and healthy community.
Examples of behavior that contributes to a positive environment for our
community include:
- Demonstrating empathy and kindness toward other people
- Being respectful of differing opinions, viewpoints, and experiences
- Giving and gracefully accepting constructive feedback
- Accepting responsibility and apologizing to those affected by our mistakes,
* Demonstrating empathy and kindness toward other people
* Being respectful of differing opinions, viewpoints, and experiences
* Giving and gracefully accepting constructive feedback
* Accepting responsibility and apologizing to those affected by our mistakes,
and learning from the experience
- Focusing on what is best not just for us as individuals, but for the
* Focusing on what is best not just for us as individuals, but for the
overall community
Examples of unacceptable behavior include:
- The use of sexualized language or imagery, and sexual attention or
* The use of sexualized language or imagery, and sexual attention or
advances of any kind
- Trolling, insulting or derogatory comments, and personal or political attacks
- Public or private harassment
- Publishing others' private information, such as a physical or email
* Trolling, insulting or derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or email
address, without their explicit permission
- Other conduct which could reasonably be considered inappropriate in a
* Other conduct which could reasonably be considered inappropriate in a
professional setting
## Language Policy
To facilitate clear and effective communication, all discussions, comments, documentation, and pull requests in this project should be conducted in English. This ensures that all contributors can participate and collaborate effectively.
+1 -1
View File
@@ -9,7 +9,7 @@ body:
required: true
- label: I confirm that I am using English to submit this report (我已阅读并同意 [Language Policy](https://github.com/langgenius/dify/issues/1542)).
required: true
- label: "[FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)"
- label: "[FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:"
required: true
- label: "Please do not modify this template :) and fill in all the required fields."
required: true
+1 -1
View File
@@ -9,7 +9,7 @@ body:
required: true
- label: I confirm that I am using English to submit this report (我已阅读并同意 [Language Policy](https://github.com/langgenius/dify/issues/1542)).
required: true
- label: "[FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)"
- label: "[FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:"
required: true
- label: "Please do not modify this template :) and fill in all the required fields."
required: true
+1 -1
View File
@@ -9,7 +9,7 @@ body:
required: true
- label: I confirm that I am using English to submit this report (我已阅读并同意 [Language Policy](https://github.com/langgenius/dify/issues/1542)).
required: true
- label: "[FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)"
- label: "[FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:"
required: true
- label: "Please do not modify this template :) and fill in all the required fields."
required: true
+6 -10
View File
@@ -8,15 +8,13 @@ body:
label: Self Checks
description: "To make sure we get to you in time, please check the following :)"
options:
- label: I have read the [Contributing Guide](https://github.com/langgenius/dify/blob/main/CONTRIBUTING.md) and [Language Policy](https://github.com/langgenius/dify/issues/1542).
required: true
- label: This is only for bug report, if you would like to ask a question, please head to [Discussions](https://github.com/langgenius/dify/discussions/categories/general).
required: true
- label: I have searched for existing issues [search for existing issues](https://github.com/langgenius/dify/issues), including closed ones.
required: true
- label: I confirm that I am using English to submit this report, otherwise it will be closed.
- label: I confirm that I am using English to submit this report (我已阅读并同意 [Language Policy](https://github.com/langgenius/dify/issues/1542)).
required: true
- label: 【中文用户 & Non English User】请使用英提交,否则会被关闭 :)
- label: "[FOR CHINESE USERS] 请务必使用英提交 Issue,否则会被关闭。谢谢!:"
required: true
- label: "Please do not modify this template :) and fill in all the required fields."
required: true
@@ -44,22 +42,20 @@ body:
attributes:
label: Steps to reproduce
description: We highly suggest including screenshots and a bug report log. Please use the right markdown syntax for code blocks.
placeholder: Having detailed steps helps us reproduce the bug. If you have logs, please use fenced code blocks (triple backticks ```) to format them.
placeholder: Having detailed steps helps us reproduce the bug.
validations:
required: true
- type: textarea
attributes:
label: ✔️ Expected Behavior
description: Describe what you expected to happen.
placeholder: What were you expecting? Please do not copy and paste the steps to reproduce here.
placeholder: What were you expecting?
validations:
required: true
required: false
- type: textarea
attributes:
label: ❌ Actual Behavior
description: Describe what actually happened.
placeholder: What happened instead? Please do not copy and paste the steps to reproduce here.
placeholder: What happened instead?
validations:
required: false
+1 -10
View File
@@ -1,14 +1,5 @@
blank_issues_enabled: false
contact_links:
- name: "\U0001F510 Security Vulnerabilities"
url: "https://github.com/langgenius/dify/security/advisories/new"
about: Report security vulnerabilities through GitHub Security Advisories to ensure responsible disclosure. 💡 Please do not report security vulnerabilities in public issues.
- name: "\U0001F4A1 Model Providers & Plugins"
url: "https://github.com/langgenius/dify-official-plugins/issues/new/choose"
about: Report issues with official plugins or model providers, you will need to provide the plugin version and other relevant details.
- name: "\U0001F4AC Documentation Issues"
url: "https://github.com/langgenius/dify-docs/issues/new"
about: Report issues with the documentation, such as typos, outdated information, or missing content. Please provide the specific section and details of the issue.
- name: "\U0001F4E7 Discussions"
url: https://github.com/langgenius/dify/discussions/categories/general
about: General discussions and seek help from the community
about: General discussions and request help from the community
+24
View File
@@ -0,0 +1,24 @@
name: "📚 Documentation Issue"
description: Report issues in our documentation
labels:
- documentation
body:
- type: checkboxes
attributes:
label: Self Checks
description: "To make sure we get to you in time, please check the following :)"
options:
- label: I have searched for existing issues [search for existing issues](https://github.com/langgenius/dify/issues), including closed ones.
required: true
- label: I confirm that I am using English to submit report (我已阅读并同意 [Language Policy](https://github.com/langgenius/dify/issues/1542)).
required: true
- label: "[FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)"
required: true
- label: "Please do not modify this template :) and fill in all the required fields."
required: true
- type: textarea
attributes:
label: Provide a description of requested docs changes
placeholder: Briefly describe which document needs to be corrected and why.
validations:
required: true
+3 -3
View File
@@ -8,11 +8,11 @@ body:
label: Self Checks
description: "To make sure we get to you in time, please check the following :)"
options:
- label: I have read the [Contributing Guide](https://github.com/langgenius/dify/blob/main/CONTRIBUTING.md) and [Language Policy](https://github.com/langgenius/dify/issues/1542).
required: true
- label: I have searched for existing issues [search for existing issues](https://github.com/langgenius/dify/issues), including closed ones.
required: true
- label: I confirm that I am using English to submit this report, otherwise it will be closed.
- label: I confirm that I am using English to submit this report (我已阅读并同意 [Language Policy](https://github.com/langgenius/dify/issues/1542)).
required: true
- label: "[FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)"
required: true
- label: "Please do not modify this template :) and fill in all the required fields."
required: true
-42
View File
@@ -1,42 +0,0 @@
name: "✨ Refactor or Chore"
description: Refactor existing code or perform maintenance chores to improve readability and reliability.
title: "[Refactor/Chore] "
body:
- type: checkboxes
attributes:
label: Self Checks
description: "To make sure we get to you in time, please check the following :)"
options:
- label: I have read the [Contributing Guide](https://github.com/langgenius/dify/blob/main/CONTRIBUTING.md) and [Language Policy](https://github.com/langgenius/dify/issues/1542).
required: true
- label: This is only for refactors or chores; if you would like to ask a question, please head to [Discussions](https://github.com/langgenius/dify/discussions/categories/general).
required: true
- label: I have searched for existing issues [search for existing issues](https://github.com/langgenius/dify/issues), including closed ones.
required: true
- label: I confirm that I am using English to submit this report, otherwise it will be closed.
required: true
- label: 【中文用户 & Non English User】请使用英语提交,否则会被关闭 :)
required: true
- label: "Please do not modify this template :) and fill in all the required fields."
required: true
- type: textarea
id: description
attributes:
label: Description
placeholder: "Describe the refactor or chore you are proposing."
validations:
required: true
- type: textarea
id: motivation
attributes:
label: Motivation
placeholder: "Explain why this refactor or chore is necessary."
validations:
required: false
- type: textarea
id: additional-context
attributes:
label: Additional Context
placeholder: "Add any other context or screenshots about the request here."
validations:
required: false
@@ -0,0 +1,55 @@
name: "🌐 Localization/Translation issue"
description: Report incorrect translations. [please use English :]
labels:
- translation
body:
- type: checkboxes
attributes:
label: Self Checks
description: "To make sure we get to you in time, please check the following :)"
options:
- label: I have searched for existing issues [search for existing issues](https://github.com/langgenius/dify/issues), including closed ones.
required: true
- label: I confirm that I am using English to submit this report (我已阅读并同意 [Language Policy](https://github.com/langgenius/dify/issues/1542)).
required: true
- label: "[FOR CHINESE USERS] 请务必使用英文提交 Issue,否则会被关闭。谢谢!:)"
required: true
- label: "Please do not modify this template :) and fill in all the required fields."
required: true
- type: input
attributes:
label: Dify version
description: Hover over system tray icon or look at Settings
validations:
required: true
- type: input
attributes:
label: Utility with translation issue
placeholder: Some area
description: Please input here the utility with the translation issue
validations:
required: true
- type: input
attributes:
label: 🌐 Language affected
placeholder: "German"
validations:
required: true
- type: textarea
attributes:
label: ❌ Actual phrase(s)
placeholder: What is there? Please include a screenshot as that is extremely helpful.
validations:
required: true
- type: textarea
attributes:
label: ✔️ Expected phrase(s)
placeholder: What was expected?
validations:
required: true
- type: textarea
attributes:
label: Why is the current translation wrong
placeholder: Why do you feel this is incorrect?
validations:
required: true
+36
View File
@@ -0,0 +1,36 @@
name: Setup Poetry and Python
inputs:
python-version:
description: Python version to use and the Poetry installed with
required: true
default: '3.11'
poetry-version:
description: Poetry version to set up
required: true
default: '2.0.1'
poetry-lockfile:
description: Path to the Poetry lockfile to restore cache from
required: true
default: ''
runs:
using: composite
steps:
- name: Set up Python ${{ inputs.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ inputs.python-version }}
cache: pip
- name: Install Poetry
shell: bash
run: pip install poetry==${{ inputs.poetry-version }}
- name: Restore Poetry cache
if: ${{ inputs.poetry-lockfile != '' }}
uses: actions/setup-python@v5
with:
python-version: ${{ inputs.python-version }}
cache: poetry
cache-dependency-path: ${{ inputs.poetry-lockfile }}
-16
View File
@@ -1,16 +0,0 @@
name: Setup Web Environment
description: Set up Node.js, Vite+, pnpm, and web dependencies
runs:
using: composite
steps:
- name: Setup pnpm
uses: pnpm/action-setup@0e279bb959325dab635dd2c09392533439d90093 # v6.0.8
with:
run_install: false
- name: Setup Vite+
uses: voidzero-dev/setup-vp@ca1c46663915d6c1042ae23bd39ab85718bfb0fa # v1.10.0
with:
node-version-file: .nvmrc
cache: true
run-install: true
-223
View File
@@ -1,223 +0,0 @@
version: 2
updates:
- package-ecosystem: "uv"
directory: "/api"
open-pull-requests-limit: 10
schedule:
interval: "weekly"
groups:
flask:
patterns:
- "flask"
- "flask-*"
- "werkzeug"
- "gunicorn"
google:
patterns:
- "google-*"
- "googleapis-*"
opentelemetry:
patterns:
- "opentelemetry-*"
pydantic:
patterns:
- "pydantic"
- "pydantic-*"
llm:
patterns:
- "langfuse"
- "langsmith"
- "litellm"
- "mlflow*"
- "opik"
- "weave*"
- "arize*"
- "tiktoken"
- "transformers"
database:
patterns:
- "sqlalchemy"
- "psycopg2*"
- "psycogreen"
- "redis*"
- "alembic*"
storage:
patterns:
- "boto3*"
- "botocore*"
- "azure-*"
- "bce-*"
- "cos-python-*"
- "esdk-obs-*"
- "google-cloud-storage"
- "opendal"
- "oss2"
- "supabase*"
- "tos*"
vdb:
patterns:
- "alibabacloud*"
- "chromadb"
- "clickhouse-*"
- "clickzetta-*"
- "couchbase"
- "elasticsearch"
- "opensearch-py"
- "oracledb"
- "pgvect*"
- "pymilvus"
- "pymochow"
- "pyobvector"
- "qdrant-client"
- "intersystems-*"
- "tablestore"
- "tcvectordb"
- "tidb-vector"
- "upstash-*"
- "volcengine-*"
- "weaviate-*"
- "xinference-*"
- "mo-vector"
- "mysql-connector-*"
dev:
patterns:
- "coverage"
- "dotenv-linter"
- "faker"
- "lxml-stubs"
- "basedpyright"
- "ruff"
- "pytest*"
- "types-*"
- "boto3-stubs"
- "hypothesis"
- "pandas-stubs"
- "scipy-stubs"
- "import-linter"
- "celery-types"
- "mypy*"
- "pyrefly"
python-packages:
patterns:
- "*"
- package-ecosystem: "github-actions"
directory: "/"
open-pull-requests-limit: 5
schedule:
interval: "weekly"
groups:
github-actions-dependencies:
patterns:
- "*"
- package-ecosystem: "uv"
directory: "/api"
target-branch: "lts/1.13.x"
open-pull-requests-limit: 10
schedule:
interval: "weekly"
groups:
flask:
patterns:
- "flask"
- "flask-*"
- "werkzeug"
- "gunicorn"
google:
patterns:
- "google-*"
- "googleapis-*"
opentelemetry:
patterns:
- "opentelemetry-*"
pydantic:
patterns:
- "pydantic"
- "pydantic-*"
llm:
patterns:
- "langfuse"
- "langsmith"
- "litellm"
- "mlflow*"
- "opik"
- "weave*"
- "arize*"
- "tiktoken"
- "transformers"
database:
patterns:
- "sqlalchemy"
- "psycopg2*"
- "psycogreen"
- "redis*"
- "alembic*"
storage:
patterns:
- "boto3*"
- "botocore*"
- "azure-*"
- "bce-*"
- "cos-python-*"
- "esdk-obs-*"
- "google-cloud-storage"
- "opendal"
- "oss2"
- "supabase*"
- "tos*"
vdb:
patterns:
- "alibabacloud*"
- "chromadb"
- "clickhouse-*"
- "clickzetta-*"
- "couchbase"
- "elasticsearch"
- "opensearch-py"
- "oracledb"
- "pgvect*"
- "pymilvus"
- "pymochow"
- "pyobvector"
- "qdrant-client"
- "intersystems-*"
- "tablestore"
- "tcvectordb"
- "tidb-vector"
- "upstash-*"
- "volcengine-*"
- "weaviate-*"
- "xinference-*"
- "mo-vector"
- "mysql-connector-*"
dev:
patterns:
- "coverage"
- "dotenv-linter"
- "faker"
- "lxml-stubs"
- "basedpyright"
- "ruff"
- "pytest*"
- "types-*"
- "boto3-stubs"
- "hypothesis"
- "pandas-stubs"
- "scipy-stubs"
- "import-linter"
- "celery-types"
- "mypy*"
- "pyrefly"
python-packages:
patterns:
- "*"
- package-ecosystem: "github-actions"
directory: "/"
target-branch: "lts/1.13.x"
open-pull-requests-limit: 5
schedule:
interval: "weekly"
groups:
github-actions-dependencies:
patterns:
- "*"
-15
View File
@@ -1,15 +0,0 @@
web:
- changed-files:
- any-glob-to-any-file:
- 'web/**'
- 'packages/**'
- 'package.json'
- 'pnpm-lock.yaml'
- 'pnpm-workspace.yaml'
- '.nvmrc'
e2e:
- changed-files:
- any-glob-to-any-file:
- 'e2e/**'
- '.github/workflows/web-e2e.yml'
-22
View File
@@ -1,22 +0,0 @@
{
"Verbose": false,
"Debug": false,
"IgnoreDefaults": false,
"SpacesAfterTabs": false,
"NoColor": false,
"Exclude": [
"^web/public/vs/",
"^web/public/pdf.worker.min.mjs$",
"web/app/components/base/icons/src/vender/"
],
"AllowedContentTypes": [],
"PassedFiles": [],
"Disable": {
"EndOfLine": false,
"Indentation": false,
"IndentSize": true,
"InsertFinalNewline": false,
"TrimTrailingWhitespace": false,
"MaxLineLength": false
}
}
+16 -15
View File
@@ -1,24 +1,25 @@
> [!IMPORTANT]
>
> 1. Make sure you have read our [contribution guidelines](https://github.com/langgenius/dify/blob/main/CONTRIBUTING.md)
> 1. Ensure there is an associated issue and you have been assigned to it
> 1. Use the correct syntax to link this PR: `Fixes #<issue number>`.
# Summary
## Summary
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.
<!-- Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change. -->
<!-- If this PR was created by an automated agent, add `From <Tool Name>` as the final line of the description. Example: `From Codex`. -->
> [!Tip]
> Close issue syntax: `Fixes #<issue number>` or `Resolves #<issue number>`, see [documentation](https://docs.github.com/en/issues/tracking-your-work-with-issues/linking-a-pull-request-to-an-issue#linking-a-pull-request-to-an-issue-using-a-keyword) for more details.
## Screenshots
# Screenshots
| Before | After |
|--------|-------|
| ... | ... |
| ... | ... |
## Checklist
# Checklist
> [!IMPORTANT]
> Please review the checklist below before submitting your pull request.
- [ ] This change requires a documentation update, included: [Dify Document](https://github.com/langgenius/dify-docs)
- [ ] I understand that this PR may be closed in case there was no previous discussion or issues. (This doesn't apply to typos!)
- [ ] I've added a test for each change that was introduced, and I tried as much as possible to make a single atomic change.
- [ ] I've updated the documentation accordingly.
- [ ] I ran `make lint && make type-check` (backend) and `cd web && pnpm exec vp staged` (frontend) to appease the lint gods
- [x] I understand that this PR may be closed in case there was no previous discussion or issues. (This doesn't apply to typos!)
- [x] I've added a test for each change that was introduced, and I tried as much as possible to make a single atomic change.
- [x] I've updated the documentation accordingly.
- [x] I ran `dev/reformat`(backend) and `cd web && npx lint-staged`(frontend) to appease the lint gods
@@ -1,73 +0,0 @@
#!/usr/bin/env bash
set -euo pipefail
BASE_SHA=${BASE_SHA:-}
HEAD_SHA=${HEAD_SHA:-}
MAIN_REF=${MAIN_REF:-origin/main}
REMEDIATION_HINT="Changes should be made from the main branch using git cherry-pick -x."
error() {
printf 'ERROR: %s\n' "$1" >&2
}
if [[ -z "$BASE_SHA" || -z "$HEAD_SHA" ]]; then
error "BASE_SHA and HEAD_SHA are required. $REMEDIATION_HINT"
exit 2
fi
if ! git rev-parse --verify "$BASE_SHA^{commit}" > /dev/null 2>&1; then
error "Base commit '$BASE_SHA' is not available in the local git checkout."
exit 2
fi
if ! git rev-parse --verify "$HEAD_SHA^{commit}" > /dev/null 2>&1; then
error "Head commit '$HEAD_SHA' is not available in the local git checkout."
exit 2
fi
if ! git rev-parse --verify "$MAIN_REF^{commit}" > /dev/null 2>&1; then
error "Main ref '$MAIN_REF' is not available in the local git checkout. $REMEDIATION_HINT"
exit 2
fi
failed=0
checked=0
while IFS= read -r commit_sha; do
[[ -n "$commit_sha" ]] || continue
checked=$((checked + 1))
subject=$(git log -1 --format=%s "$commit_sha")
source_sha=$(
git log -1 --format=%B "$commit_sha" \
| sed -nE 's/^\(cherry picked from commit ([0-9a-fA-F]{7,64})\)$/\1/p' \
| tail -n 1
)
if [[ -z "$source_sha" ]]; then
error "Commit $commit_sha ($subject) is missing cherry-pick provenance. $REMEDIATION_HINT If version differences prevent using git cherry-pick -x, manually add '(cherry picked from commit <sha>)' to the commit message."
failed=1
continue
fi
if ! git cat-file -e "$source_sha^{commit}" 2> /dev/null; then
error "Commit $commit_sha ($subject) references source $source_sha, but that commit is not available locally. $REMEDIATION_HINT"
failed=1
continue
fi
if ! git merge-base --is-ancestor "$source_sha" "$MAIN_REF"; then
error "Commit $commit_sha ($subject) references source $source_sha, but that source is not reachable from main ($MAIN_REF). $REMEDIATION_HINT"
failed=1
fi
done < <(git rev-list --reverse "$BASE_SHA..$HEAD_SHA")
if [[ "$failed" -ne 0 ]]; then
exit 1
fi
if [[ "$checked" -eq 0 ]]; then
echo "No PR commits to check."
else
echo "Verified $checked PR commit(s) include cherry-pick provenance from main."
fi
-82
View File
@@ -1,82 +0,0 @@
import { execFileSync } from 'node:child_process'
import fs from 'node:fs'
import path from 'node:path'
const repoRoot = process.cwd()
const baseSha = process.env.BASE_SHA || ''
const headSha = process.env.HEAD_SHA || ''
const files = (process.env.CHANGED_FILES || '').split(/\s+/).filter(Boolean)
const outputPath = process.env.I18N_CHANGES_OUTPUT_PATH || '/tmp/i18n-changes.json'
const englishPath = fileStem => path.join(repoRoot, 'web', 'i18n', 'en-US', `${fileStem}.json`)
const readCurrentJson = (fileStem) => {
const filePath = englishPath(fileStem)
if (!fs.existsSync(filePath))
return null
return JSON.parse(fs.readFileSync(filePath, 'utf8'))
}
const readBaseJson = (fileStem) => {
if (!baseSha)
return null
try {
const relativePath = `web/i18n/en-US/${fileStem}.json`
const content = execFileSync('git', ['show', `${baseSha}:${relativePath}`], { encoding: 'utf8' })
return JSON.parse(content)
}
catch {
return null
}
}
const compareJson = (beforeValue, afterValue) => JSON.stringify(beforeValue) === JSON.stringify(afterValue)
const changes = {}
for (const fileStem of files) {
const currentJson = readCurrentJson(fileStem)
const beforeJson = readBaseJson(fileStem) || {}
const afterJson = currentJson || {}
const added = {}
const updated = {}
const deleted = []
for (const [key, value] of Object.entries(afterJson)) {
if (!(key in beforeJson)) {
added[key] = value
continue
}
if (!compareJson(beforeJson[key], value)) {
updated[key] = {
before: beforeJson[key],
after: value,
}
}
}
for (const key of Object.keys(beforeJson)) {
if (!(key in afterJson))
deleted.push(key)
}
changes[fileStem] = {
fileDeleted: currentJson === null,
added,
updated,
deleted,
}
}
fs.writeFileSync(
outputPath,
JSON.stringify({
baseSha,
headSha,
files,
changes,
})
)
+45 -173
View File
@@ -1,204 +1,76 @@
name: Run Pytest
on:
workflow_call:
secrets:
CODECOV_TOKEN:
required: false
permissions:
contents: read
pull_request:
branches:
- main
- plugins/beta
paths:
- api/**
- docker/**
- .github/workflows/api-tests.yml
concurrency:
group: api-tests-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
api-unit:
name: API Unit Tests
runs-on: depot-ubuntu-24.04
env:
COVERAGE_FILE: coverage-unit
defaults:
run:
shell: bash
test:
name: API Tests
runs-on: ubuntu-latest
strategy:
matrix:
python-version:
- "3.11"
- "3.12"
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
persist-credentials: false
uses: actions/checkout@v4
- name: Setup UV and Python
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
- name: Setup Poetry and Python ${{ matrix.python-version }}
uses: ./.github/actions/setup-poetry
with:
enable-cache: true
python-version: ${{ matrix.python-version }}
cache-dependency-glob: api/uv.lock
poetry-lockfile: api/poetry.lock
- name: Check UV lockfile
run: uv lock --project api --check
- name: Check Poetry lockfile
run: |
poetry check -C api --lock
poetry show -C api
- name: Install dependencies
run: uv sync --project api --dev
run: poetry install -C api --with dev
- name: Check dependencies in pyproject.toml
run: poetry run -P api bash dev/pytest/pytest_artifacts.sh
- name: Run Unit tests
run: poetry run -P api bash dev/pytest/pytest_unit_tests.sh
- name: Run dify config tests
run: uv run --project api pytest api/tests/unit_tests/configs/test_env_consistency.py
run: poetry run -P api python dev/pytest/pytest_config_tests.py
- name: Run Unit Tests
- name: Run mypy
run: |
uv run --project api pytest \
-p no:benchmark \
--timeout "${PYTEST_TIMEOUT:-20}" \
-n auto \
api/tests/unit_tests \
api/providers/vdb/*/tests/unit_tests \
api/providers/trace/*/tests/unit_tests \
--ignore=api/tests/unit_tests/controllers
# Controller tests register Flask routes at import time, so keep them out of xdist.
uv run --project api pytest \
--timeout "${PYTEST_TIMEOUT:-20}" \
--cov-append \
api/tests/unit_tests/controllers
poetry run -C api python -m mypy --install-types --non-interactive .
- name: Upload unit coverage data
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: api-coverage-unit
path: coverage-unit
retention-days: 1
api-integration:
name: API Integration Tests
runs-on: depot-ubuntu-24.04
env:
COVERAGE_FILE: coverage-integration
STORAGE_TYPE: opendal
OPENDAL_SCHEME: fs
OPENDAL_FS_ROOT: /tmp/dify-storage
defaults:
run:
shell: bash
strategy:
matrix:
python-version:
- "3.12"
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
persist-credentials: false
- name: Setup UV and Python
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
with:
enable-cache: true
python-version: ${{ matrix.python-version }}
cache-dependency-glob: api/uv.lock
- name: Check UV lockfile
run: uv lock --project api --check
- name: Install dependencies
run: uv sync --project api --dev
- name: Run Integration Tests
- name: Set up dotenvs
run: |
uv run --project api pytest \
-p no:benchmark \
--start-middleware \
-n auto \
--timeout "${PYTEST_TIMEOUT:-180}" \
api/tests/integration_tests/workflow \
api/tests/integration_tests/tools \
api/tests/test_containers_integration_tests
cp docker/.env.example docker/.env
cp docker/middleware.env.example docker/middleware.env
- name: Upload integration coverage data
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
- name: Expose Service Ports
run: sh .github/workflows/expose_service_ports.sh
- name: Set up Sandbox
uses: hoverkraft-tech/compose-action@v2.0.2
with:
name: api-coverage-integration
path: coverage-integration
retention-days: 1
compose-file: |
docker/docker-compose.middleware.yaml
services: |
sandbox
ssrf_proxy
api-coverage:
name: API Coverage
runs-on: depot-ubuntu-24.04
needs:
- api-unit
- api-integration
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
COVERAGE_FILE: .coverage
defaults:
run:
shell: bash
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
persist-credentials: false
- name: Setup UV and Python
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
with:
enable-cache: true
python-version: "3.12"
cache-dependency-glob: api/uv.lock
- name: Install dependencies
run: uv sync --project api --dev
- name: Download coverage data
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
with:
path: coverage-data
pattern: api-coverage-*
merge-multiple: true
- name: Combine coverage
run: |
set -euo pipefail
echo "### API Coverage" >> "$GITHUB_STEP_SUMMARY"
echo "" >> "$GITHUB_STEP_SUMMARY"
echo "Merged backend coverage report generated for Codecov project status." >> "$GITHUB_STEP_SUMMARY"
echo "" >> "$GITHUB_STEP_SUMMARY"
unit_coverage="$(find coverage-data -type f -name coverage-unit -print -quit)"
integration_coverage="$(find coverage-data -type f -name coverage-integration -print -quit)"
: "${unit_coverage:?coverage-unit artifact not found}"
: "${integration_coverage:?coverage-integration artifact not found}"
report_file="$(mktemp)"
uv run --project api coverage combine "$unit_coverage" "$integration_coverage"
uv run --project api coverage report --show-missing | tee "$report_file"
echo "Summary: \`$(tail -n 1 "$report_file")\`" >> "$GITHUB_STEP_SUMMARY"
{
echo ""
echo "<details><summary>Coverage report</summary>"
echo ""
echo '```'
cat "$report_file"
echo '```'
echo "</details>"
} >> "$GITHUB_STEP_SUMMARY"
uv run --project api coverage xml -o coverage.xml
- name: Report coverage
if: ${{ env.CODECOV_TOKEN != '' }}
uses: codecov/codecov-action@fb8b3582c8e4def4969c97caa2f19720cb33a72f # v7.0.0
with:
files: ./coverage.xml
disable_search: true
flags: api
env:
CODECOV_TOKEN: ${{ env.CODECOV_TOKEN }}
- name: Run Workflow
run: poetry run -P api bash dev/pytest/pytest_workflow.sh
-181
View File
@@ -1,181 +0,0 @@
name: autofix.ci
on:
pull_request:
branches: ["main"]
merge_group:
branches: ["main"]
types: [checks_requested]
push:
branches: ["main"]
permissions:
contents: read
jobs:
autofix:
if: github.repository == 'langgenius/dify'
runs-on: depot-ubuntu-24.04-4
steps:
- name: Complete merge group check
if: github.event_name == 'merge_group'
run: echo "autofix.ci updates pull request branches, not merge group refs."
- if: github.event_name != 'merge_group'
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: Check Docker Compose inputs
if: github.event_name != 'merge_group'
id: docker-compose-changes
uses: tj-actions/changed-files@9426d40962ed5378910ee2e21d5f8c6fcbf2dd96 # v47.0.6
with:
files: |
docker/generate_docker_compose
docker/.env.example
docker/docker-compose-template.yaml
docker/docker-compose.yaml
- name: Check web inputs
if: github.event_name != 'merge_group'
id: web-changes
uses: tj-actions/changed-files@9426d40962ed5378910ee2e21d5f8c6fcbf2dd96 # v47.0.6
with:
files: |
web/**
cli/**
e2e/**
packages/**
sdks/nodejs-client/**
package.json
pnpm-lock.yaml
pnpm-workspace.yaml
.nvmrc
vite.config.ts
lint.config.ts
eslint.config.mjs
oxlint-suppressions.json
eslint-suppressions.json
.vscode/**
.github/workflows/autofix.yml
.github/workflows/style.yml
- name: Check api inputs
if: github.event_name != 'merge_group'
id: api-changes
uses: tj-actions/changed-files@9426d40962ed5378910ee2e21d5f8c6fcbf2dd96 # v47.0.6
with:
files: |
api/**
- name: Check frontend contract inputs
if: github.event_name != 'merge_group'
id: frontend-contract-changes
uses: tj-actions/changed-files@9426d40962ed5378910ee2e21d5f8c6fcbf2dd96 # v47.0.6
with:
files: |
api/**
packages/contracts/openapi-ts.api.config.ts
packages/contracts/package.json
packages/contracts/openapi/**
pnpm-lock.yaml
pnpm-workspace.yaml
- name: Check dify-agent inputs
if: github.event_name != 'merge_group'
id: dify-agent-changes
uses: tj-actions/changed-files@9426d40962ed5378910ee2e21d5f8c6fcbf2dd96 # v47.0.6
with:
files: |
dify-agent/**/*.py
dify-agent/pyproject.toml
dify-agent/uv.lock
- if: github.event_name != 'merge_group'
uses: actions/setup-python@ece7cb06caefa5fff74198d8649806c4678c61a1 # v6.3.0
with:
python-version: "3.11"
- if: github.event_name != 'merge_group'
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
- name: Generate Docker Compose
if: github.event_name != 'merge_group' && steps.docker-compose-changes.outputs.any_changed == 'true'
run: |
cd docker
./generate_docker_compose
- if: github.event_name != 'merge_group' && steps.api-changes.outputs.any_changed == 'true'
run: |
cd api
uv sync --dev
# fmt first to avoid line too long
uv run ruff format ..
# Fix lint errors
uv run ruff check --fix .
# Format code
uv run ruff format ..
- if: github.event_name != 'merge_group' && steps.dify-agent-changes.outputs.any_changed == 'true'
run: |
cd dify-agent
uv sync --dev
# fmt first to avoid line too long
uv run ruff format .
# Fix lint errors
uv run ruff check --fix .
# Format code
uv run ruff format .
- name: count migration progress
if: github.event_name != 'merge_group' && steps.api-changes.outputs.any_changed == 'true'
run: |
cd api
./cnt_base.sh
- name: ast-grep
if: github.event_name != 'merge_group' && steps.api-changes.outputs.any_changed == 'true'
run: |
# ast-grep exits 1 if no matches are found; allow idempotent runs.
uvx --from ast-grep-cli ast-grep --pattern 'db.session.query($WHATEVER).filter($HERE)' --rewrite 'db.session.query($WHATEVER).where($HERE)' -l py --update-all || true
uvx --from ast-grep-cli ast-grep --pattern 'session.query($WHATEVER).filter($HERE)' --rewrite 'session.query($WHATEVER).where($HERE)' -l py --update-all || true
uvx --from ast-grep-cli ast-grep -p '$A = db.Column($$$B)' -r '$A = mapped_column($$$B)' -l py --update-all || true
uvx --from ast-grep-cli ast-grep -p '$A : $T = db.Column($$$B)' -r '$A : $T = mapped_column($$$B)' -l py --update-all || true
# Convert Optional[T] to T | None (ignoring quoted types)
cat > /tmp/optional-rule.yml << 'EOF'
id: convert-optional-to-union
language: python
rule:
kind: generic_type
all:
- has:
kind: identifier
pattern: Optional
- has:
kind: type_parameter
has:
kind: type
pattern: $T
fix: $T | None
EOF
uvx --from ast-grep-cli ast-grep scan . --inline-rules "$(cat /tmp/optional-rule.yml)" --update-all
# Fix forward references that were incorrectly converted (Python doesn't support "Type" | None syntax)
find . -name "*.py" -type f -exec sed -i.bak -E 's/"([^"]+)" \| None/Optional["\1"]/g; s/'"'"'([^'"'"']+)'"'"' \| None/Optional['"'"'\1'"'"']/g' {} \;
find . -name "*.py.bak" -type f -delete
- name: Setup web environment
if: github.event_name != 'merge_group'
uses: ./.github/actions/setup-web
- name: Generate API docs
if: github.event_name != 'merge_group' && steps.api-changes.outputs.any_changed == 'true'
run: |
cd api
uv run dev/generate_swagger_markdown_docs.py --swagger-dir ../packages/contracts/openapi --markdown-dir openapi/markdown --keep-swagger-json
- name: Generate frontend contracts
if: github.event_name != 'merge_group' && steps.frontend-contract-changes.outputs.any_changed == 'true'
run: pnpm --dir packages/contracts gen-api-contract
- name: ESLint fallback autofix
if: github.event_name != 'merge_group' && steps.web-changes.outputs.any_changed == 'true'
run: pnpm lint:eslint:fix --quiet || true
- name: Vite+ static autofix
if: github.event_name != 'merge_group' && (steps.web-changes.outputs.any_changed == 'true' || steps.frontend-contract-changes.outputs.any_changed == 'true')
run: vp check --fix || true
- if: github.event_name != 'merge_group'
uses: autofix-ci/action@c5b2d67aa2274e7b5a18224e8171550871fc7e4a # v1.3.4
+44 -119
View File
@@ -4,12 +4,11 @@ on:
push:
branches:
- "main"
- "deploy/**"
- "build/**"
- "release/e-*"
- "hotfix/**"
tags:
- "*"
- "deploy/dev"
- "plugins/beta"
- "dev/plugin-deploy"
release:
types: [published]
concurrency:
group: build-push-${{ github.head_ref || github.run_id }}
@@ -20,75 +19,30 @@ env:
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
DIFY_WEB_IMAGE_NAME: ${{ vars.DIFY_WEB_IMAGE_NAME || 'langgenius/dify-web' }}
DIFY_API_IMAGE_NAME: ${{ vars.DIFY_API_IMAGE_NAME || 'langgenius/dify-api' }}
DIFY_AGENT_IMAGE_NAME: ${{ vars.DIFY_AGENT_IMAGE_NAME || 'langgenius/dify-agent-backend' }}
DIFY_AGENT_LOCAL_SANDBOX_IMAGE_NAME: ${{ vars.DIFY_AGENT_LOCAL_SANDBOX_IMAGE_NAME || 'langgenius/dify-agent-local-sandbox' }}
jobs:
build:
runs-on: ${{ matrix.runs_on }}
runs-on: ${{ matrix.platform == 'linux/arm64' && 'arm64_runner' || 'ubuntu-latest' }}
if: github.repository == 'langgenius/dify'
permissions:
contents: read
id-token: write
strategy:
matrix:
include:
- service_name: "build-api-amd64"
image_name_env: "DIFY_API_IMAGE_NAME"
artifact_context: "api"
build_context: "{{defaultContext}}"
file: "api/Dockerfile"
context: "api"
platform: linux/amd64
runs_on: depot-ubuntu-24.04-4
- service_name: "build-api-arm64"
image_name_env: "DIFY_API_IMAGE_NAME"
artifact_context: "api"
build_context: "{{defaultContext}}"
file: "api/Dockerfile"
context: "api"
platform: linux/arm64
runs_on: depot-ubuntu-24.04-4
- service_name: "build-web-amd64"
image_name_env: "DIFY_WEB_IMAGE_NAME"
artifact_context: "web"
build_context: "{{defaultContext}}"
file: "web/Dockerfile"
context: "web"
platform: linux/amd64
runs_on: depot-ubuntu-24.04-4
- service_name: "build-web-arm64"
image_name_env: "DIFY_WEB_IMAGE_NAME"
artifact_context: "web"
build_context: "{{defaultContext}}"
file: "web/Dockerfile"
context: "web"
platform: linux/arm64
runs_on: depot-ubuntu-24.04-4
- service_name: "build-agent-amd64"
image_name_env: "DIFY_AGENT_IMAGE_NAME"
artifact_context: "agent"
build_context: "{{defaultContext}}"
file: "dify-agent/Dockerfile"
platform: linux/amd64
runs_on: depot-ubuntu-24.04-4
- service_name: "build-agent-arm64"
image_name_env: "DIFY_AGENT_IMAGE_NAME"
artifact_context: "agent"
build_context: "{{defaultContext}}"
file: "dify-agent/Dockerfile"
platform: linux/arm64
runs_on: depot-ubuntu-24.04-4
- service_name: "build-agent-local-sandbox-amd64"
image_name_env: "DIFY_AGENT_LOCAL_SANDBOX_IMAGE_NAME"
artifact_context: "local-sandbox"
build_context: "{{defaultContext}}:dify-agent-runtime"
file: "docker/Dockerfile"
platform: linux/amd64
runs_on: depot-ubuntu-24.04-4
- service_name: "build-agent-local-sandbox-arm64"
image_name_env: "DIFY_AGENT_LOCAL_SANDBOX_IMAGE_NAME"
artifact_context: "local-sandbox"
build_context: "{{defaultContext}}:dify-agent-runtime"
file: "docker/Dockerfile"
platform: linux/arm64
runs_on: depot-ubuntu-24.04-4
steps:
- name: Prepare
@@ -97,83 +51,52 @@ jobs:
echo "PLATFORM_PAIR=${platform//\//-}" >> $GITHUB_ENV
- name: Login to Docker Hub
uses: docker/login-action@af1e73f918a031802d376d3c8bbc3fe56130a9b0 # v4.4.0
uses: docker/login-action@v3
with:
username: ${{ env.DOCKERHUB_USER }}
password: ${{ env.DOCKERHUB_TOKEN }}
- name: Set up Depot CLI
uses: depot/setup-action@15c09a5f77a0840ad4bce955686522a257853461 # v1.7.1
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Extract metadata for Docker
id: meta
uses: docker/metadata-action@dc802804100637a589fabce1cb79ff13a1411302 # v6.2.0
uses: docker/metadata-action@v5
with:
images: ${{ env[matrix.image_name_env] }}
- name: Build Docker image
id: build
uses: depot/build-push-action@98e78adca7817480b8185f474a400b451d74e287 # v1.18.0
uses: docker/build-push-action@v6
with:
project: ${{ vars.DEPOT_PROJECT_ID }}
context: ${{ matrix.build_context }}
file: ${{ matrix.file }}
context: "{{defaultContext}}:${{ matrix.context }}"
platforms: ${{ matrix.platform }}
build-args: COMMIT_SHA=${{ fromJSON(steps.meta.outputs.json).labels['org.opencontainers.image.revision'] }}
build-contexts: ${{ matrix.build_contexts }}
labels: ${{ steps.meta.outputs.labels }}
outputs: type=image,name=${{ env[matrix.image_name_env] }},push-by-digest=true,name-canonical=true,push=true
cache-from: type=gha,scope=${{ matrix.service_name }}
cache-to: type=gha,mode=max,scope=${{ matrix.service_name }}
- name: Export digest
env:
DIGEST: ${{ steps.build.outputs.digest }}
run: |
mkdir -p /tmp/digests
sanitized_digest=${DIGEST#sha256:}
touch "/tmp/digests/${sanitized_digest}"
digest="${{ steps.build.outputs.digest }}"
touch "/tmp/digests/${digest#sha256:}"
- name: Upload digest
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
uses: actions/upload-artifact@v4
with:
name: digests-${{ matrix.artifact_context }}-${{ env.PLATFORM_PAIR }}
name: digests-${{ matrix.context }}-${{ env.PLATFORM_PAIR }}
path: /tmp/digests/*
if-no-files-found: error
retention-days: 1
fork-build-validate:
if: github.repository != 'langgenius/dify'
runs-on: ubuntu-24.04
strategy:
matrix:
include:
- service_name: "validate-api-amd64"
build_context: "{{defaultContext}}"
file: "api/Dockerfile"
- service_name: "validate-web-amd64"
build_context: "{{defaultContext}}"
file: "web/Dockerfile"
- service_name: "validate-agent-amd64"
build_context: "{{defaultContext}}"
file: "dify-agent/Dockerfile"
- service_name: "validate-agent-local-sandbox-amd64"
build_context: "{{defaultContext}}:dify-agent-runtime"
file: "docker/Dockerfile"
steps:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4.2.0
- name: Validate Docker image
uses: docker/build-push-action@53b7df96c91f9c12dcc8a07bcb9ccacbed38856a # v7.3.0
with:
push: false
context: ${{ matrix.build_context }}
file: ${{ matrix.file }}
build-contexts: ${{ matrix.build_contexts }}
platforms: linux/amd64
create-manifest:
needs: build
runs-on: depot-ubuntu-24.04
runs-on: ubuntu-latest
if: github.repository == 'langgenius/dify'
strategy:
matrix:
@@ -184,29 +107,23 @@ jobs:
- service_name: "merge-web-images"
image_name_env: "DIFY_WEB_IMAGE_NAME"
context: "web"
- service_name: "merge-agent-images"
image_name_env: "DIFY_AGENT_IMAGE_NAME"
context: "agent"
- service_name: "merge-agent-local-sandbox-images"
image_name_env: "DIFY_AGENT_LOCAL_SANDBOX_IMAGE_NAME"
context: "local-sandbox"
steps:
- name: Download digests
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
uses: actions/download-artifact@v4
with:
path: /tmp/digests
pattern: digests-${{ matrix.context }}-*
merge-multiple: true
- name: Login to Docker Hub
uses: docker/login-action@af1e73f918a031802d376d3c8bbc3fe56130a9b0 # v4.4.0
uses: docker/login-action@v3
with:
username: ${{ env.DOCKERHUB_USER }}
password: ${{ env.DOCKERHUB_TOKEN }}
- name: Extract metadata for Docker
id: meta
uses: docker/metadata-action@dc802804100637a589fabce1cb79ff13a1411302 # v6.2.0
uses: docker/metadata-action@v5
with:
images: ${{ env[matrix.image_name_env] }}
tags: |
@@ -217,15 +134,23 @@ jobs:
- name: Create manifest list and push
working-directory: /tmp/digests
env:
IMAGE_NAME: ${{ env[matrix.image_name_env] }}
run: |
docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
$(printf "$IMAGE_NAME@sha256:%s " *)
$(printf '${{ env[matrix.image_name_env] }}@sha256:%s ' *)
- name: Inspect image
env:
IMAGE_NAME: ${{ env[matrix.image_name_env] }}
IMAGE_VERSION: ${{ steps.meta.outputs.version }}
run: |
docker buildx imagetools inspect "$IMAGE_NAME:$IMAGE_VERSION"
docker buildx imagetools inspect ${{ env[matrix.image_name_env] }}:${{ steps.meta.outputs.version }}
- name: print context var
uses: actions/checkout@v4
- name: deploy pod in plugin env
if: github.ref == 'refs/heads/dev/plugin-deploy'
env:
IMAGEHASH: ${{ github.sha }}
APICMD: "${{ secrets.PLUGIN_CD_API_CURL }}"
WEBCMD: "${{ secrets.PLUGIN_CD_WEB_CURL }}"
run: |
bash -c "${APICMD/yourNewVersion/$IMAGEHASH}"
bash -c "${WEBCMD/yourNewVersion/$IMAGEHASH}"
-415
View File
@@ -1,415 +0,0 @@
name: CLI E2E Tests
on:
workflow_dispatch:
inputs:
cli_ref:
description: "Git ref (default: current branch)"
type: string
required: false
edition:
description: "Dify edition"
type: choice
required: false
default: ee
options: [ee, ce]
test_scope:
description: "smoke = [P0] only / full = all cases"
type: choice
required: false
default: full
options: [smoke, full]
# ── Suite on/off ────────────────────────────────────────────────────────
suite_framework_output_error:
description: "framework + output + error-handling suites"
type: boolean
default: true
suite_discovery:
description: "discovery suite (get app / describe app)"
type: boolean
default: true
suite_run:
description: "run suite (basic / streaming / conversation / file / hitl)"
type: boolean
default: true
suite_auth:
description: "auth suite (login / status / whoami / use / devices / logout)"
type: boolean
default: true
suite_agent:
description: "agent suite"
type: boolean
default: true
permissions:
contents: read
# ── Shared env injected into every E2E job ───────────────────────────────────
# Each job reads DIFY_E2E_TOKEN + app IDs from the provision job outputs,
# so global-setup skips minting and finds existing apps in < 10 s.
env:
DIFY_E2E_NO_KEYRING: "1" # Linux CI has no keychain; skip probe
VITEST_RETRY: "2" # Retry flaky staging responses
jobs:
# ════════════════════════════════════════════════════════════════════════════
# 0. PROVISION — mint token + import DSL fixtures (runs once, outputs IDs)
# ════════════════════════════════════════════════════════════════════════════
provision:
name: "Provision: mint token + DSL apps"
runs-on: ubuntu-latest
timeout-minutes: 10
outputs:
token: ${{ steps.out.outputs.DIFY_E2E_TOKEN }}
workspace_id: ${{ steps.out.outputs.DIFY_E2E_WORKSPACE_ID }}
workspace_name: ${{ steps.out.outputs.DIFY_E2E_WORKSPACE_NAME }}
ws2_id: ${{ steps.out.outputs.DIFY_E2E_WS2_ID }}
chat_app_id: ${{ steps.out.outputs.DIFY_E2E_CHAT_APP_ID }}
workflow_app_id: ${{ steps.out.outputs.DIFY_E2E_WORKFLOW_APP_ID }}
file_app_id: ${{ steps.out.outputs.DIFY_E2E_FILE_APP_ID }}
file_chat_app_id: ${{ steps.out.outputs.DIFY_E2E_FILE_CHAT_APP_ID }}
hitl_app_id: ${{ steps.out.outputs.DIFY_E2E_HITL_APP_ID }}
hitl_external_app_id: ${{ steps.out.outputs.DIFY_E2E_HITL_EXTERNAL_APP_ID }}
hitl_single_action_app_id: ${{ steps.out.outputs.DIFY_E2E_HITL_SINGLE_ACTION_APP_ID }}
hitl_multi_node_app_id: ${{ steps.out.outputs.DIFY_E2E_HITL_MULTI_NODE_APP_ID }}
ws2_app_id: ${{ steps.out.outputs.DIFY_E2E_WS2_APP_ID }}
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v4
with:
ref: ${{ inputs.cli_ref || github.ref }}
persist-credentials: false
- uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9
with:
package_json_field: packageManager
run_install: false
- name: Install CLI dependencies
working-directory: cli
run: pnpm install --frozen-lockfile
- name: Mint token & provision apps
id: out
working-directory: cli
env:
DIFY_E2E_HOST: ${{ secrets.DIFY_E2E_HOST }}
DIFY_E2E_EMAIL: ${{ secrets.DIFY_E2E_EMAIL }}
DIFY_E2E_PASSWORD: ${{ secrets.DIFY_E2E_PASSWORD }}
DIFY_E2E_TOKEN: ${{ secrets.DIFY_E2E_TOKEN }}
DIFY_E2E_EDITION: ${{ inputs.edition || 'ee' }}
run: bun scripts/e2e-provision.ts
# ════════════════════════════════════════════════════════════════════════════
# 1-B. framework + output + error-handling (parallel with run/discovery)
# ════════════════════════════════════════════════════════════════════════════
suite-framework-output-error:
name: "Suite: framework + output + error-handling"
if: ${{ inputs.suite_framework_output_error != 'false' }}
needs: provision
runs-on: ubuntu-latest
timeout-minutes: 20
defaults:
run:
working-directory: cli
shell: bash
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v4
with:
ref: ${{ inputs.cli_ref || github.ref }}
persist-credentials: false
- uses: ./.github/actions/setup-web
- uses: oven-sh/setup-bun@v2
with: { bun-version: latest }
- uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9
with: { package_json_field: packageManager, run_install: false }
- run: pnpm install --frozen-lockfile
- run: pnpm tree:gen
- name: Run framework + output + error-handling
env:
DIFY_E2E_HOST: ${{ secrets.DIFY_E2E_HOST }}
DIFY_E2E_EMAIL: ${{ secrets.DIFY_E2E_EMAIL }}
DIFY_E2E_PASSWORD: ${{ secrets.DIFY_E2E_PASSWORD }}
DIFY_E2E_EDITION: ${{ inputs.edition || 'ee' }}
DIFY_E2E_TOKEN: ${{ needs.provision.outputs.token }}
DIFY_E2E_WORKSPACE_ID: ${{ needs.provision.outputs.workspace_id }}
DIFY_E2E_WORKSPACE_NAME: ${{ needs.provision.outputs.workspace_name }}
DIFY_E2E_CHAT_APP_ID: ${{ needs.provision.outputs.chat_app_id }}
DIFY_E2E_WORKFLOW_APP_ID: ${{ needs.provision.outputs.workflow_app_id }}
DIFY_E2E_INCLUDE: "test/e2e/suites/framework/**/*.e2e.ts,test/e2e/suites/output/**/*.e2e.ts,test/e2e/suites/error-handling/**/*.e2e.ts"
run: |
if [ "${{ inputs.test_scope }}" = "smoke" ]; then
pnpm test:e2e -- -t "\[P0\]"
else
pnpm test:e2e
fi
# ════════════════════════════════════════════════════════════════════════════
# 1-C. Discovery (parallel)
# ════════════════════════════════════════════════════════════════════════════
suite-discovery:
name: "Suite: discovery"
if: ${{ inputs.suite_discovery != 'false' }}
needs: provision
runs-on: ubuntu-latest
timeout-minutes: 20
defaults:
run:
working-directory: cli
shell: bash
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v4
with:
ref: ${{ inputs.cli_ref || github.ref }}
persist-credentials: false
- uses: ./.github/actions/setup-web
- uses: oven-sh/setup-bun@v2
with: { bun-version: latest }
- uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9
with: { package_json_field: packageManager, run_install: false }
- run: pnpm install --frozen-lockfile
- run: pnpm tree:gen
- name: Run discovery suite
env:
DIFY_E2E_HOST: ${{ secrets.DIFY_E2E_HOST }}
DIFY_E2E_EMAIL: ${{ secrets.DIFY_E2E_EMAIL }}
DIFY_E2E_PASSWORD: ${{ secrets.DIFY_E2E_PASSWORD }}
DIFY_E2E_EDITION: ${{ inputs.edition || 'ee' }}
DIFY_E2E_TOKEN: ${{ needs.provision.outputs.token }}
DIFY_E2E_WORKSPACE_ID: ${{ needs.provision.outputs.workspace_id }}
DIFY_E2E_WORKSPACE_NAME: ${{ needs.provision.outputs.workspace_name }}
DIFY_E2E_WS2_ID: ${{ needs.provision.outputs.ws2_id }}
DIFY_E2E_CHAT_APP_ID: ${{ needs.provision.outputs.chat_app_id }}
DIFY_E2E_WORKFLOW_APP_ID: ${{ needs.provision.outputs.workflow_app_id }}
DIFY_E2E_INCLUDE: "test/e2e/suites/discovery/**/*.e2e.ts"
run: |
if [ "${{ inputs.test_scope }}" = "smoke" ]; then
pnpm test:e2e -- -t "\[P0\]"
else
pnpm test:e2e
fi
# ════════════════════════════════════════════════════════════════════════════
# 1-D. Run suite — 5 files in matrix (parallel)
# ════════════════════════════════════════════════════════════════════════════
suite-run:
name: "Suite: run / ${{ matrix.name }}"
if: ${{ inputs.suite_run != 'false' }}
needs: provision
runs-on: ubuntu-latest
timeout-minutes: 20
strategy:
fail-fast: false
matrix:
include:
- name: basic
file: run-app-basic.e2e.ts
- name: streaming
file: run-app-streaming.e2e.ts
- name: conversation
file: run-app-conversation.e2e.ts
- name: file
file: run-app-file.e2e.ts
- name: hitl
file: run-app-hitl.e2e.ts
defaults:
run:
working-directory: cli
shell: bash
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v4
with:
ref: ${{ inputs.cli_ref || github.ref }}
persist-credentials: false
- uses: ./.github/actions/setup-web
- uses: oven-sh/setup-bun@v2
with: { bun-version: latest }
- uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9
with: { package_json_field: packageManager, run_install: false }
- run: pnpm install --frozen-lockfile
- run: pnpm tree:gen
- name: "Run run/${{ matrix.name }}"
env:
DIFY_E2E_HOST: ${{ secrets.DIFY_E2E_HOST }}
DIFY_E2E_EMAIL: ${{ secrets.DIFY_E2E_EMAIL }}
DIFY_E2E_PASSWORD: ${{ secrets.DIFY_E2E_PASSWORD }}
DIFY_E2E_EDITION: ${{ inputs.edition || 'ee' }}
DIFY_E2E_SSO_TOKEN: ${{ secrets.DIFY_E2E_SSO_TOKEN }}
DIFY_E2E_TOKEN: ${{ needs.provision.outputs.token }}
DIFY_E2E_WORKSPACE_ID: ${{ needs.provision.outputs.workspace_id }}
DIFY_E2E_WORKSPACE_NAME: ${{ needs.provision.outputs.workspace_name }}
DIFY_E2E_CHAT_APP_ID: ${{ needs.provision.outputs.chat_app_id }}
DIFY_E2E_WORKFLOW_APP_ID: ${{ needs.provision.outputs.workflow_app_id }}
DIFY_E2E_FILE_APP_ID: ${{ needs.provision.outputs.file_app_id }}
DIFY_E2E_FILE_CHAT_APP_ID: ${{ needs.provision.outputs.file_chat_app_id }}
DIFY_E2E_HITL_APP_ID: ${{ needs.provision.outputs.hitl_app_id }}
DIFY_E2E_HITL_EXTERNAL_APP_ID: ${{ needs.provision.outputs.hitl_external_app_id }}
DIFY_E2E_HITL_SINGLE_ACTION_APP_ID: ${{ needs.provision.outputs.hitl_single_action_app_id }}
DIFY_E2E_HITL_MULTI_NODE_APP_ID: ${{ needs.provision.outputs.hitl_multi_node_app_id }}
DIFY_E2E_INCLUDE: "test/e2e/suites/run/${{ matrix.file }}"
run: |
if [ "${{ inputs.test_scope }}" = "smoke" ]; then
pnpm test:e2e -- -t "\[P0\]"
else
pnpm test:e2e
fi
- name: Upload results on failure
if: failure()
uses: actions/upload-artifact@v7
with:
name: e2e-run-${{ matrix.name }}-${{ github.run_id }}
path: cli/test-results/
retention-days: 3
# ════════════════════════════════════════════════════════════════════════════
# 1-E. auth/login + status + whoami (parallel, read-only, safe)
# ════════════════════════════════════════════════════════════════════════════
suite-auth-safe:
name: "Suite: auth (login / status / whoami)"
if: ${{ inputs.suite_auth != 'false' }}
needs: provision
runs-on: ubuntu-latest
timeout-minutes: 15
defaults:
run:
working-directory: cli
shell: bash
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v4
with:
ref: ${{ inputs.cli_ref || github.ref }}
persist-credentials: false
- uses: ./.github/actions/setup-web
- uses: oven-sh/setup-bun@v2
with: { bun-version: latest }
- uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9
with: { package_json_field: packageManager, run_install: false }
- run: pnpm install --frozen-lockfile
- run: pnpm tree:gen
- name: Run auth/login + status + whoami
env:
DIFY_E2E_HOST: ${{ secrets.DIFY_E2E_HOST }}
DIFY_E2E_EMAIL: ${{ secrets.DIFY_E2E_EMAIL }}
DIFY_E2E_PASSWORD: ${{ secrets.DIFY_E2E_PASSWORD }}
DIFY_E2E_EDITION: ${{ inputs.edition || 'ee' }}
DIFY_E2E_TOKEN: ${{ needs.provision.outputs.token }}
DIFY_E2E_WORKSPACE_ID: ${{ needs.provision.outputs.workspace_id }}
DIFY_E2E_WORKSPACE_NAME: ${{ needs.provision.outputs.workspace_name }}
DIFY_E2E_WS2_ID: ${{ needs.provision.outputs.ws2_id }}
DIFY_E2E_INCLUDE: "test/e2e/suites/auth/login.e2e.ts,test/e2e/suites/auth/status.e2e.ts,test/e2e/suites/auth/whoami.e2e.ts"
run: |
if [ "${{ inputs.test_scope }}" = "smoke" ]; then
pnpm test:e2e -- -t "\[P0\]"
else
pnpm test:e2e
fi
# ════════════════════════════════════════════════════════════════════════════
# 2. DESTRUCTIVE — auth/use + devices + logout + agent (serial, runs LAST)
# Must wait for ALL parallel suites to finish to avoid token revocation
# invalidating other in-flight requests.
# ════════════════════════════════════════════════════════════════════════════
suite-last:
name: "Suite: auth-use + devices + logout + agent (last, serial)"
# Runs when auth is selected; also runs after all parallel jobs finish
if: ${{ inputs.suite_auth != 'false' || inputs.suite_agent != 'false' }}
needs:
- provision
- suite-framework-output-error
- suite-discovery
- suite-run
- suite-auth-safe
# `needs` on a skipped job is treated as success — safe to proceed even if
# some suites were disabled via toggle.
runs-on: ubuntu-latest
timeout-minutes: 25
defaults:
run:
working-directory: cli
shell: bash
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v4
with:
ref: ${{ inputs.cli_ref || github.ref }}
persist-credentials: false
- uses: ./.github/actions/setup-web
- uses: oven-sh/setup-bun@v2
with: { bun-version: latest }
- uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9
with: { package_json_field: packageManager, run_install: false }
- run: pnpm install --frozen-lockfile
- run: pnpm tree:gen
- name: Run use / devices / logout / agent (serial)
env:
DIFY_E2E_HOST: ${{ secrets.DIFY_E2E_HOST }}
DIFY_E2E_EMAIL: ${{ secrets.DIFY_E2E_EMAIL }}
DIFY_E2E_PASSWORD: ${{ secrets.DIFY_E2E_PASSWORD }}
DIFY_E2E_EDITION: ${{ inputs.edition || 'ee' }}
DIFY_E2E_TOKEN: ${{ needs.provision.outputs.token }}
DIFY_E2E_WORKSPACE_ID: ${{ needs.provision.outputs.workspace_id }}
DIFY_E2E_WORKSPACE_NAME: ${{ needs.provision.outputs.workspace_name }}
DIFY_E2E_WS2_ID: ${{ needs.provision.outputs.ws2_id }}
DIFY_E2E_CHAT_APP_ID: ${{ needs.provision.outputs.chat_app_id }}
DIFY_E2E_WORKFLOW_APP_ID: ${{ needs.provision.outputs.workflow_app_id }}
DIFY_E2E_HITL_APP_ID: ${{ needs.provision.outputs.hitl_app_id }}
DIFY_E2E_HITL_EXTERNAL_APP_ID: ${{ needs.provision.outputs.hitl_external_app_id }}
DIFY_E2E_HITL_SINGLE_ACTION_APP_ID: ${{ needs.provision.outputs.hitl_single_action_app_id }}
DIFY_E2E_HITL_MULTI_NODE_APP_ID: ${{ needs.provision.outputs.hitl_multi_node_app_id }}
run: |
# Collect files in safe order: use → devices → logout (revokes last) → agent
FILES=()
if [ "${{ inputs.suite_auth }}" = "true" ]; then
FILES+=(
test/e2e/suites/auth/use.e2e.ts
test/e2e/suites/auth/devices.e2e.ts
test/e2e/suites/auth/logout.e2e.ts
)
fi
if [ "${{ inputs.suite_agent }}" = "true" ]; then
while IFS= read -r f; do FILES+=("$f"); done \
< <(find test/e2e/suites/agent -name '*.e2e.ts' | sort)
fi
[ ${#FILES[@]} -eq 0 ] && { echo "Nothing to run."; exit 0; }
# Pass files via DIFY_E2E_INCLUDE (comma-separated) so vitest
# config's include list is overridden instead of ANDed.
INCLUDE=$(IFS=,; echo "${FILES[*]}")
if [ "${{ inputs.test_scope }}" = "smoke" ]; then
DIFY_E2E_INCLUDE="$INCLUDE" pnpm test:e2e -- -t "\[P0\]"
else
DIFY_E2E_INCLUDE="$INCLUDE" pnpm test:e2e
fi
- name: Upload results on failure
if: failure()
uses: actions/upload-artifact@v7
with:
name: e2e-last-${{ github.run_id }}
path: cli/test-results/
retention-days: 3
-74
View File
@@ -1,74 +0,0 @@
name: CLI Edge Publish
on:
push:
branches: [main]
paths:
- 'cli/**'
- 'packages/contracts/generated/api/openapi/**'
workflow_dispatch:
concurrency:
group: difyctl-edge-publish
cancel-in-progress: false
jobs:
publish:
name: build + publish edge to R2
runs-on: ${{ github.repository == 'langgenius/dify' && 'depot-ubuntu-24.04' || 'ubuntu-24.04' }}
if: vars.DIFYCTL_R2_BUCKET != ''
defaults:
run:
shell: bash
working-directory: ./cli
steps:
- name: Checkout
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
fetch-depth: 0
- name: Enable cross-arch native prebuilds
working-directory: ./
run: cat cli/scripts/cross-arch.pnpm.yaml >> pnpm-workspace.yaml
- name: Setup web environment
uses: ./.github/actions/setup-web
- name: Setup Bun
uses: oven-sh/setup-bun@4bc047ad259df6fc24a6c9b0f9a0cb08cf17fbe5 # v2.0.2
with:
bun-version-file: cli/.bun-version
- name: Compute edge version
id: ver
run: echo "version=$(node scripts/release-naming.mjs edge-version "$(git rev-parse --short HEAD)")" >> "$GITHUB_OUTPUT"
- name: Compile standalone binaries (all targets, all-or-nothing)
run: |
CLI_VERSION="${{ steps.ver.outputs.version }}" \
DIFYCTL_CHANNEL=edge \
DIFYCTL_COMMIT="$(git rev-parse HEAD)" \
DIFYCTL_BUILD_DATE="$(git log -1 --format=%cI HEAD)" \
pnpm build:bin
- name: Generate sha256 checksums
run: CLI_VERSION="${{ steps.ver.outputs.version }}" scripts/release-write-checksums.sh
- name: Smoke the runner-arch binary
run: ./dist/bin/difyctl-v${{ steps.ver.outputs.version }}-linux-x64 version
- name: Publish to R2
env:
AWS_ACCESS_KEY_ID: ${{ secrets.DIFYCTL_R2_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DIFYCTL_R2_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: auto
AWS_REQUEST_CHECKSUM_CALCULATION: WHEN_REQUIRED
AWS_RESPONSE_CHECKSUM_VALIDATION: WHEN_REQUIRED
DIFYCTL_R2_S3_ENDPOINT: ${{ vars.DIFYCTL_R2_S3_ENDPOINT }}
DIFYCTL_R2_BUCKET: ${{ vars.DIFYCTL_R2_BUCKET }}
DIFYCTL_R2_PUBLIC_BASE: ${{ vars.DIFYCTL_R2_PUBLIC_BASE }}
DIFYCTL_COMMIT: ${{ github.sha }}
run: |
DIFYCTL_BUILD_DATE="$(git log -1 --format=%cI HEAD)" \
scripts/release-r2-publish.sh edge "${{ steps.ver.outputs.version }}"
-166
View File
@@ -1,166 +0,0 @@
name: CLI Release
on:
workflow_dispatch:
inputs:
release_tag:
description: Dify release tag to attach difyctl assets to (blank = latest stable)
required: false
type: string
workflow_call:
inputs:
release_tag:
description: Dify release tag to attach difyctl assets to (blank = latest stable)
required: false
type: string
release:
types: [released]
concurrency:
group: difyctl-release
cancel-in-progress: false
jobs:
validate:
name: validate manifest + resolve target Dify release
runs-on: depot-ubuntu-24.04
if: github.repository == 'langgenius/dify'
permissions:
contents: read
defaults:
run:
shell: bash
working-directory: ./cli
outputs:
dify_tag: ${{ steps.resolve.outputs.dify_tag }}
steps:
- name: Checkout
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
- name: Export manifest to env
run: node scripts/release-naming.mjs github-env >> "$GITHUB_ENV"
- name: Validate manifest
run: scripts/release-validate-manifest.sh
- name: Resolve target Dify release
id: resolve
env:
GH_TOKEN: ${{ github.token }}
EVENT_TAG: ${{ github.event.release.tag_name }}
INPUT_TAG: ${{ inputs.release_tag }}
run: |
if [ -n "$EVENT_TAG" ]; then
tag="$EVENT_TAG"
elif [ -n "$INPUT_TAG" ]; then
tag="$INPUT_TAG"
else
tag="$(gh api "repos/${GITHUB_REPOSITORY}/releases/latest" --jq .tag_name)"
fi
if [ -z "$tag" ]; then
echo "::error::could not resolve a target Dify release tag"
exit 1
fi
if ! gh release view "$tag" --repo "$GITHUB_REPOSITORY" >/dev/null 2>&1; then
echo "::error::target Dify release ${tag} not found"
exit 1
fi
echo "dify_tag=${tag}" >> "$GITHUB_OUTPUT"
echo "::notice::target Dify release ${tag}"
- name: Compatibility check
env:
DIFY_TAG: ${{ steps.resolve.outputs.dify_tag }}
run: node scripts/release-naming.mjs compat-check "$DIFY_TAG"
- name: Reject duplicate difyctl version
env:
GH_TOKEN: ${{ github.token }}
run: |
if gh api "repos/${GITHUB_REPOSITORY}/git/ref/tags/${difyctlTag}" >/dev/null 2>&1; then
echo "::error::difyctl ${version} already released (tag ${difyctlTag} exists); bump cli/package.json version"
exit 1
fi
release:
name: build + attach standalone binaries (all targets)
needs: validate
runs-on: depot-ubuntu-24.04
permissions:
contents: write
defaults:
run:
shell: bash
working-directory: ./cli
env:
DIFY_TAG: ${{ needs.validate.outputs.dify_tag }}
steps:
- name: Checkout
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
fetch-depth: 1
- name: Enable cross-arch native prebuilds
working-directory: ./
run: cat cli/scripts/cross-arch.pnpm.yaml >> pnpm-workspace.yaml
- name: Setup web environment
uses: ./.github/actions/setup-web
- name: Export manifest to env
run: node scripts/release-naming.mjs github-env >> "$GITHUB_ENV"
- name: Setup Bun
uses: oven-sh/setup-bun@4bc047ad259df6fc24a6c9b0f9a0cb08cf17fbe5 # v2.0.2
with:
bun-version-file: cli/.bun-version
- name: Compile standalone binaries (all targets)
run: |
DIFYCTL_COMMIT="$(git rev-parse HEAD)" \
DIFYCTL_BUILD_DATE="$(git log -1 --format=%cI HEAD)" \
pnpm build:bin
- name: Generate sha256 checksum file
run: scripts/release-write-checksums.sh
- name: Attach difyctl assets to Dify release
env:
GH_TOKEN: ${{ github.token }}
run: |
gh release upload "$DIFY_TAG" dist/bin/${tagPrefix}* \
--repo "$GITHUB_REPOSITORY" --clobber
- name: Prune stale difyctl assets
env:
GH_TOKEN: ${{ github.token }}
run: |
new_set="$(cd dist/bin && ls ${tagPrefix}*)"
gh release view "$DIFY_TAG" --repo "$GITHUB_REPOSITORY" \
--json assets --jq '.assets[].name' \
| { grep -E "^${tagPrefix}" || true; } \
| while IFS= read -r name; do
if ! printf '%s\n' "$new_set" | grep -qxF -- "$name"; then
echo "::notice::pruning stale asset ${name}"
gh release delete-asset "$DIFY_TAG" "$name" \
--repo "$GITHUB_REPOSITORY" --yes
fi
done
- name: Create provenance tag
env:
GH_TOKEN: ${{ github.token }}
run: |
ref="refs/tags/${difyctlTag}"
sha="$(git rev-parse HEAD)"
status="$(gh api -X POST "repos/${GITHUB_REPOSITORY}/git/refs" \
-f ref="$ref" -f sha="$sha" --silent --include 2>/dev/null \
| awk 'NR==1 {print $2; exit}' || true)"
case "$status" in
201) echo "::notice::created ${ref}" ;;
422) echo "::notice::tag ${ref} already exists; skipping (immutable)" ;;
*) echo "::error::provenance tag ${ref} not created (HTTP ${status:-unknown})"; exit 1 ;;
esac
-60
View File
@@ -1,60 +0,0 @@
name: CLI Smoke (live dify)
on:
workflow_dispatch:
inputs:
dify_version:
description: "Dify image tag to test against (e.g. 1.7.0)"
type: string
required: true
cli_ref:
description: "Git ref to build the cli from (default: current branch)"
type: string
required: false
permissions:
contents: read
jobs:
smoke:
runs-on: ubuntu-latest
timeout-minutes: 30
defaults:
run:
shell: bash
steps:
- name: Checkout cli ref
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
ref: ${{ inputs.cli_ref || github.ref }}
persist-credentials: false
- name: Setup web environment
uses: ./.github/actions/setup-web
- name: Bring up dify
env:
DIFY_VERSION: ${{ inputs.dify_version }}
run: |
cd docker
cp .env.example .env
DIFY_API_IMAGE_TAG="$DIFY_VERSION" \
DIFY_WEB_IMAGE_TAG="$DIFY_VERSION" \
docker compose up -d api worker web db redis
for i in $(seq 1 60); do
if curl -fsS http://localhost:5001/health >/dev/null 2>&1; then
echo "dify api ready after ${i}s"
break
fi
sleep 1
done
- name: Run smoke against live dify
working-directory: ./cli
run: pnpm exec tsx scripts/run-smoke.ts --base-url http://localhost:5001
- name: Dump dify logs on failure
if: failure()
run: |
cd docker
docker compose logs api worker web --tail=200
-59
View File
@@ -1,59 +0,0 @@
name: CLI Tests
on:
workflow_call:
secrets:
CODECOV_TOKEN:
required: false
permissions:
contents: read
concurrency:
group: cli-tests-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
test:
name: CLI Tests (${{ matrix.os }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [depot-ubuntu-24.04, windows-latest, macos-latest]
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
defaults:
run:
shell: bash
working-directory: ./cli
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
- name: Setup web environment
uses: ./.github/actions/setup-web
- name: Setup Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- name: Validate release manifest
if: matrix.os == 'depot-ubuntu-24.04'
run: scripts/release-validate-manifest.sh
- name: CI pipeline (tree, coverage, build)
run: pnpm run ci
- name: Report coverage
if: ${{ env.CODECOV_TOKEN != '' && matrix.os == 'depot-ubuntu-24.04' }}
uses: codecov/codecov-action@fb8b3582c8e4def4969c97caa2f19720cb33a72f # v7.0.0
with:
directory: cli/coverage
flags: cli
env:
CODECOV_TOKEN: ${{ env.CODECOV_TOKEN }}
+18 -100
View File
@@ -1,51 +1,46 @@
name: DB Migration Test
on:
workflow_call:
pull_request:
branches:
- main
- plugins/beta
paths:
- api/migrations/**
- .github/workflows/db-migration-test.yml
concurrency:
group: db-migration-test-${{ github.ref }}
cancel-in-progress: true
jobs:
db-migration-test-postgres:
runs-on: depot-ubuntu-24.04
db-migration-test:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
persist-credentials: false
uses: actions/checkout@v4
- name: Setup UV and Python
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
- name: Setup Poetry and Python
uses: ./.github/actions/setup-poetry
with:
enable-cache: true
python-version: "3.12"
cache-dependency-glob: api/uv.lock
poetry-lockfile: api/poetry.lock
- name: Install dependencies
run: uv sync --project api
- name: Ensure Offline migration are supported
run: |
# upgrade
uv run --directory api flask db upgrade 'base:head' --sql
# downgrade
uv run --directory api flask db downgrade 'head:base' --sql
run: poetry install -C api
- name: Prepare middleware env
run: |
cd docker
cp envs/middleware.env.example middleware.env
cp middleware.env.example middleware.env
- name: Set up Middlewares
uses: hoverkraft-tech/compose-action@11beaa1c2dae4e8ed7b1665aa074723b6cecb0e4 # v3.0.0
uses: hoverkraft-tech/compose-action@v2.0.2
with:
compose-file: |
docker/docker-compose.middleware.yaml
services: |
db_postgres
db
redis
- name: Prepare configs
@@ -56,83 +51,6 @@ jobs:
- name: Run DB Migration
env:
DEBUG: true
run: uv run --directory api flask upgrade-db
db-migration-test-mysql:
runs-on: depot-ubuntu-24.04
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
persist-credentials: false
- name: Setup UV and Python
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
with:
enable-cache: true
python-version: "3.12"
cache-dependency-glob: api/uv.lock
- name: Install dependencies
run: uv sync --project api
- name: Ensure Offline migration are supported
run: |
# upgrade
uv run --directory api flask db upgrade 'base:head' --sql
# downgrade
uv run --directory api flask db downgrade 'head:base' --sql
- name: Prepare middleware env for MySQL
run: |
cd docker
cp envs/middleware.env.example middleware.env
sed -i 's/DB_TYPE=postgresql/DB_TYPE=mysql/' middleware.env
sed -i 's/DB_HOST=db_postgres/DB_HOST=db_mysql/' middleware.env
sed -i 's/DB_PORT=5432/DB_PORT=3306/' middleware.env
sed -i 's/DB_USERNAME=postgres/DB_USERNAME=mysql/' middleware.env
- name: Set up Middlewares
uses: hoverkraft-tech/compose-action@11beaa1c2dae4e8ed7b1665aa074723b6cecb0e4 # v3.0.0
with:
compose-file: |
docker/docker-compose.middleware.yaml
services: |
db_mysql
redis
- name: Prepare configs for MySQL
run: |
cd api
cp .env.example .env
sed -i 's/DB_TYPE=postgresql/DB_TYPE=mysql/' .env
sed -i 's/DB_PORT=5432/DB_PORT=3306/' .env
sed -i 's/DB_USERNAME=postgres/DB_USERNAME=root/' .env
# hoverkraft-tech/compose-action@v2.6.0 only waits for `docker compose up -d`
# to return (container processes started); it does not wait on healthcheck
# status. mysql:8.0's first-time init takes 15-30s, so without an explicit
# wait the migration runs while InnoDB is still initialising and gets
# killed with "Lost connection during query". Poll a real SELECT until it
# succeeds.
- name: Wait for MySQL to accept queries
run: |
set +e
for i in $(seq 1 60); do
if docker run --rm --network host mysql:8.0 \
mysql -h 127.0.0.1 -P 3306 -uroot -pdifyai123456 \
-e 'SELECT 1' >/dev/null 2>&1; then
echo "MySQL ready after ${i}s"
exit 0
fi
sleep 1
done
echo "MySQL not ready after 60s; dumping container logs:"
docker compose -f docker/docker-compose.middleware.yaml --profile mysql logs --tail=200 db_mysql
exit 1
- name: Run DB Migration
env:
DEBUG: true
run: uv run --directory api flask upgrade-db
poetry run python -m flask upgrade-db
-28
View File
@@ -1,28 +0,0 @@
name: Deploy Agent
permissions:
contents: read
on:
workflow_run:
workflows: ["Build and Push API & Web"]
branches:
- "deploy/agent"
types:
- completed
jobs:
deploy:
runs-on: depot-ubuntu-24.04
if: |
github.event.workflow_run.conclusion == 'success' &&
github.event.workflow_run.head_branch == 'deploy/agent'
steps:
- name: Deploy to server
uses: appleboy/ssh-action@0ff4204d59e8e51228ff73bce53f80d53301dee2 # v1.2.5
with:
host: ${{ secrets.AGENT_SSH_HOST }}
username: ${{ secrets.SSH_USER }}
key: ${{ secrets.SSH_PRIVATE_KEY }}
script: |
${{ vars.SSH_SCRIPT_AGENT || secrets.SSH_SCRIPT_AGENT }}
+3 -4
View File
@@ -10,13 +10,12 @@ on:
jobs:
deploy:
runs-on: depot-ubuntu-24.04
runs-on: ubuntu-latest
if: |
github.event.workflow_run.conclusion == 'success' &&
github.event.workflow_run.head_branch == 'deploy/dev'
github.event.workflow_run.conclusion == 'success'
steps:
- name: Deploy to server
uses: appleboy/ssh-action@0ff4204d59e8e51228ff73bce53f80d53301dee2 # v1.2.5
uses: appleboy/ssh-action@v0.1.8
with:
host: ${{ secrets.SSH_HOST }}
username: ${{ secrets.SSH_USER }}
-41
View File
@@ -1,41 +0,0 @@
name: Deploy Enterprise
permissions:
contents: read
on:
workflow_run:
workflows: ["Build and Push API & Web"]
branches:
- "deploy/enterprise"
types:
- completed
jobs:
deploy:
runs-on: depot-ubuntu-24.04
if: |
github.event.workflow_run.conclusion == 'success' &&
github.event.workflow_run.head_branch == 'deploy/enterprise'
steps:
- name: trigger deployments
env:
DEV_ENV_ADDRS: ${{ vars.DEV_ENV_ADDRS }}
DEPLOY_SECRET: ${{ secrets.DEPLOY_SECRET }}
run: |
IFS=',' read -ra ENDPOINTS <<< "${DEV_ENV_ADDRS:-}"
BODY='{"project":"dify-api","tag":"deploy-enterprise"}'
for ENDPOINT in "${ENDPOINTS[@]}"; do
ENDPOINT="$(echo "$ENDPOINT" | xargs)"
[ -z "$ENDPOINT" ] && continue
API_SIGNATURE=$(printf '%s' "$BODY" | openssl dgst -sha256 -hmac "$DEPLOY_SECRET" | awk '{print "sha256="$2}')
curl -sSf -X POST \
-H "Content-Type: application/json" \
-H "X-Hub-Signature-256: $API_SIGNATURE" \
-d "$BODY" \
"$ENDPOINT"
done
+23
View File
@@ -0,0 +1,23 @@
name: Deploy Plugin Dev
on:
workflow_run:
workflows: ["Build and Push API & Web"]
branches:
- "dev/plugin-deploy"
types:
- completed
jobs:
deploy:
runs-on: ubuntu-latest
if: |
github.event.workflow_run.conclusion == 'success'
steps:
- name: Deploy to server
uses: appleboy/ssh-action@v0.1.8
with:
host: ${{ secrets.SSH_HOST }}
username: ${{ secrets.SSH_USER }}
key: ${{ secrets.SSH_PRIVATE_KEY }}
script: "echo 123"
-28
View File
@@ -1,28 +0,0 @@
name: Deploy SaaS
permissions:
contents: read
on:
workflow_run:
workflows: ["Build and Push API & Web"]
branches:
- "deploy/saas"
types:
- completed
jobs:
deploy:
runs-on: depot-ubuntu-24.04
if: |
github.event.workflow_run.conclusion == 'success' &&
github.event.workflow_run.head_branch == 'deploy/saas'
steps:
- name: Deploy to server
uses: appleboy/ssh-action@0ff4204d59e8e51228ff73bce53f80d53301dee2 # v1.2.5
with:
host: ${{ secrets.SAAS_DEV_SSH_HOST }}
username: ${{ secrets.SSH_USER }}
key: ${{ secrets.SSH_PRIVATE_KEY }}
script: |
${{ vars.SSH_SCRIPT_SAAS_DEV || secrets.SSH_SCRIPT_SAAS_DEV }}
+13 -74
View File
@@ -6,18 +6,7 @@ on:
- "main"
paths:
- api/Dockerfile
- api/Dockerfile.dockerignore
- api/pyproject.toml
- api/uv.lock
- dify-agent/pyproject.toml
- dify-agent/README.md
- dify-agent/src/**
- web/Dockerfile
- dify-agent-runtime/docker/Dockerfile
- dify-agent-runtime/go.mod
- dify-agent-runtime/go.sum
- dify-agent-runtime/cmd/**
- dify-agent-runtime/internal/**
concurrency:
group: docker-build-${{ github.head_ref || github.run_id }}
@@ -25,84 +14,34 @@ concurrency:
jobs:
build-docker:
if: github.event.pull_request.head.repo.full_name == github.repository
runs-on: ${{ matrix.runs_on }}
permissions:
contents: read
id-token: write
runs-on: ubuntu-latest
strategy:
matrix:
include:
- service_name: "api-amd64"
platform: linux/amd64
runs_on: depot-ubuntu-24.04-4
context: "{{defaultContext}}"
file: "api/Dockerfile"
context: "api"
- service_name: "api-arm64"
platform: linux/arm64
runs_on: depot-ubuntu-24.04-4
context: "{{defaultContext}}"
file: "api/Dockerfile"
context: "api"
- service_name: "web-amd64"
platform: linux/amd64
runs_on: depot-ubuntu-24.04-4
context: "{{defaultContext}}"
file: "web/Dockerfile"
context: "web"
- service_name: "web-arm64"
platform: linux/arm64
runs_on: depot-ubuntu-24.04-4
context: "{{defaultContext}}"
file: "web/Dockerfile"
- service_name: "local-sandbox-amd64"
platform: linux/amd64
runs_on: depot-ubuntu-24.04-4
context: "{{defaultContext}}:dify-agent-runtime"
file: "docker/Dockerfile"
- service_name: "local-sandbox-arm64"
platform: linux/arm64
runs_on: depot-ubuntu-24.04-4
context: "{{defaultContext}}:dify-agent-runtime"
file: "docker/Dockerfile"
context: "web"
steps:
- name: Set up Depot CLI
uses: depot/setup-action@15c09a5f77a0840ad4bce955686522a257853461 # v1.7.1
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Build Docker Image
uses: depot/build-push-action@98e78adca7817480b8185f474a400b451d74e287 # v1.18.0
with:
project: ${{ vars.DEPOT_PROJECT_ID }}
push: false
context: ${{ matrix.context }}
file: ${{ matrix.file }}
build-contexts: ${{ matrix.build_contexts }}
platforms: ${{ matrix.platform }}
build-docker-fork:
if: github.event.pull_request.head.repo.full_name != github.repository
runs-on: ubuntu-24.04
permissions:
contents: read
strategy:
matrix:
include:
- service_name: "api-amd64"
context: "{{defaultContext}}"
file: "api/Dockerfile"
- service_name: "web-amd64"
context: "{{defaultContext}}"
file: "web/Dockerfile"
- service_name: "local-sandbox-amd64"
context: "{{defaultContext}}:dify-agent-runtime"
file: "docker/Dockerfile"
steps:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4.2.0
uses: docker/setup-buildx-action@v3
- name: Build Docker Image
uses: docker/build-push-action@53b7df96c91f9c12dcc8a07bcb9ccacbed38856a # v7.3.0
uses: docker/build-push-action@v6
with:
push: false
context: ${{ matrix.context }}
file: ${{ matrix.file }}
build-contexts: ${{ matrix.build_contexts }}
platforms: linux/amd64
context: "{{defaultContext}}:${{ matrix.context }}"
platforms: ${{ matrix.platform }}
cache-from: type=gha
cache-to: type=gha,mode=max
+14
View File
@@ -0,0 +1,14 @@
#!/bin/bash
yq eval '.services.weaviate.ports += ["8080:8080"]' -i docker/docker-compose.yaml
yq eval '.services.qdrant.ports += ["6333:6333"]' -i docker/docker-compose.yaml
yq eval '.services.chroma.ports += ["8000:8000"]' -i docker/docker-compose.yaml
yq eval '.services["milvus-standalone"].ports += ["19530:19530"]' -i docker/docker-compose.yaml
yq eval '.services.pgvector.ports += ["5433:5432"]' -i docker/docker-compose.yaml
yq eval '.services["pgvecto-rs"].ports += ["5431:5432"]' -i docker/docker-compose.yaml
yq eval '.services["elasticsearch"].ports += ["9200:9200"]' -i docker/docker-compose.yaml
yq eval '.services.couchbase-server.ports += ["8091-8096:8091-8096"]' -i docker/docker-compose.yaml
yq eval '.services.couchbase-server.ports += ["11210:11210"]' -i docker/docker-compose.yaml
yq eval '.services.tidb.ports += ["4000:4000"]' -i docker/docker-compose.yaml
echo "Ports exposed for sandbox, weaviate, tidb, qdrant, chroma, milvus, pgvector, pgvecto-rs, elasticsearch, couchbase"
-49
View File
@@ -1,49 +0,0 @@
name: Hotfix Cherry-Pick Provenance
on:
pull_request:
branches:
- 'hotfix/**'
- 'lts/**'
types:
- opened
- edited
- reopened
- ready_for_review
- synchronize
permissions:
contents: read
concurrency:
group: hotfix-cherry-pick-${{ github.event.pull_request.number || github.run_id }}
cancel-in-progress: true
jobs:
check-cherry-pick-provenance:
name: Require cherry-pick provenance
runs-on: depot-ubuntu-24.04
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
- name: Fetch PR base, PR head, and main
env:
BASE_REF: ${{ github.base_ref }}
PR_NUMBER: ${{ github.event.pull_request.number }}
run: |
git fetch --no-tags --prune origin \
"+refs/heads/main:refs/remotes/origin/main" \
"+refs/heads/${BASE_REF}:refs/remotes/origin/${BASE_REF}" \
"+refs/pull/${PR_NUMBER}/head:refs/remotes/pull/${PR_NUMBER}/head"
- name: Load checker from main
run: git show origin/main:.github/scripts/check-hotfix-cherry-picks.sh > "$RUNNER_TEMP/check-hotfix-cherry-picks.sh"
- name: Check PR commits
env:
BASE_SHA: ${{ github.event.pull_request.base.sha }}
HEAD_SHA: ${{ github.event.pull_request.head.sha }}
MAIN_REF: origin/main
run: bash "$RUNNER_TEMP/check-hotfix-cherry-picks.sh"
-14
View File
@@ -1,14 +0,0 @@
name: "Pull Request Labeler"
on:
pull_request_target:
jobs:
labeler:
permissions:
contents: read
pull-requests: write
runs-on: depot-ubuntu-24.04
steps:
- uses: actions/labeler@b8dd2d9be0f68b860e7dae5dae7d772984eacd6d # v6.2.0
with:
sync-labels: true
-576
View File
@@ -1,576 +0,0 @@
name: Main CI Pipeline
on:
pull_request:
branches: ["main"]
merge_group:
branches: ["main"]
types: [checks_requested]
permissions:
actions: write
contents: write
pull-requests: write
checks: write
statuses: write
concurrency:
group: main-ci-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
pre_job:
name: Skip Duplicate Checks
runs-on: depot-ubuntu-24.04
outputs:
should_skip: ${{ steps.skip_check.outputs.should_skip || 'false' }}
steps:
- id: skip_check
continue-on-error: true
uses: fkirc/skip-duplicate-actions@f75f66ce1886f00957d99748a42c724f4330bdcf # v5.3.1
with:
cancel_others: 'true'
concurrent_skipping: same_content_newer
# Check which paths were changed to determine which tests to run
check-changes:
name: Check Changed Files
needs: pre_job
if: needs.pre_job.outputs.should_skip != 'true'
runs-on: depot-ubuntu-24.04
outputs:
api-changed: ${{ steps.changes.outputs.api }}
cli-changed: ${{ steps.changes.outputs.cli }}
e2e-changed: ${{ steps.changes.outputs.e2e }}
web-changed: ${{ steps.changes.outputs.web }}
vdb-changed: ${{ steps.changes.outputs.vdb }}
migration-changed: ${{ steps.changes.outputs.migration }}
sandbox-runtime-changed: ${{ steps.changes.outputs.sandbox-runtime }}
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- uses: dorny/paths-filter@7b450fff21473bca461d4b92ce414b9d0420d706 # v4.0.2
id: changes
with:
filters: |
api:
- 'api/**'
- 'scripts/ast_grep_guard.py'
- 'scripts/check_no_new_getattr.py'
- 'scripts/check_no_new_controller_sqlalchemy.py'
- 'scripts/lint_controller_sqlalchemy.py'
- 'scripts/ast_grep_rules/no_new_getattr.yml'
- 'scripts/ast_grep_rules/no_new_controller_sqlalchemy.yml'
- '.github/workflows/style.yml'
- '.github/workflows/main-ci.yml'
- '.github/workflows/api-tests.yml'
- 'docker/.env.example'
- 'docker/envs/middleware.env.example'
- 'docker/docker-compose.middleware.yaml'
- 'docker/docker-compose-template.yaml'
- 'docker/generate_docker_compose'
- 'docker/ssrf_proxy/**'
- 'docker/volumes/sandbox/conf/**'
cli:
- 'cli/**'
- 'packages/contracts/**'
- 'packages/tsconfig/**'
- 'package.json'
- 'pnpm-lock.yaml'
- 'pnpm-workspace.yaml'
- 'lint.config.ts'
- '.npmrc'
- '.nvmrc'
- '.github/workflows/cli-tests.yml'
- '.github/workflows/cli-docker-build.yml'
- '.github/actions/setup-web/**'
web:
- 'web/**'
- 'packages/**'
- 'package.json'
- 'pnpm-lock.yaml'
- 'pnpm-workspace.yaml'
- '.nvmrc'
- '.github/workflows/web-tests.yml'
- '.github/actions/setup-web/**'
e2e:
- 'api/**'
- 'api/pyproject.toml'
- 'api/uv.lock'
- 'e2e/**'
- 'web/**'
- 'packages/**'
- 'package.json'
- 'pnpm-lock.yaml'
- 'pnpm-workspace.yaml'
- '.nvmrc'
- 'docker/docker-compose.middleware.yaml'
- 'docker/envs/middleware.env.example'
- '.github/workflows/web-e2e.yml'
- '.github/workflows/main-ci.yml'
- '.github/actions/setup-web/**'
vdb:
- 'api/core/rag/datasource/**'
- 'api/tests/integration_tests/vdb/**'
- 'api/conftest.py'
- 'api/tests/pytest_dify.py'
- 'api/providers/vdb/*/tests/**'
- '.github/workflows/vdb-tests.yml'
- 'docker/.env.example'
- 'docker/envs/middleware.env.example'
- 'docker/docker-compose.pytest.ports.yaml'
- 'docker/docker-compose.yaml'
- 'docker/docker-compose-template.yaml'
- 'docker/generate_docker_compose'
- 'docker/certbot/**'
- 'docker/couchbase-server/**'
- 'docker/elasticsearch/**'
- 'docker/iris/**'
- 'docker/nginx/**'
- 'docker/pgvector/**'
- 'docker/ssrf_proxy/**'
- 'docker/startupscripts/**'
- 'docker/tidb/**'
- 'docker/volumes/**'
- 'api/uv.lock'
- 'api/pyproject.toml'
sandbox-runtime:
- 'dify-agent-runtime/**'
- '.github/workflows/sandbox-runtime-tests.yml'
migration:
- 'api/migrations/**'
- 'api/.env.example'
- '.github/workflows/db-migration-test.yml'
- 'docker/.env.example'
- 'docker/envs/middleware.env.example'
- 'docker/docker-compose.middleware.yaml'
- 'docker/docker-compose-template.yaml'
- 'docker/generate_docker_compose'
- 'docker/ssrf_proxy/**'
- 'docker/volumes/sandbox/conf/**'
# Run tests in parallel while always emitting stable required checks.
api-tests-run:
name: Run API Tests
needs:
- pre_job
- check-changes
if: needs.pre_job.outputs.should_skip != 'true' && needs.check-changes.outputs.api-changed == 'true'
uses: ./.github/workflows/api-tests.yml
secrets: inherit
api-tests-skip:
name: Skip API Tests
needs:
- pre_job
- check-changes
if: needs.pre_job.outputs.should_skip != 'true' && needs.check-changes.outputs.api-changed != 'true'
runs-on: depot-ubuntu-24.04
steps:
- name: Report skipped API tests
run: echo "No API-related changes detected; skipping API tests."
api-tests:
name: API Tests
if: ${{ always() }}
needs:
- pre_job
- check-changes
- api-tests-run
- api-tests-skip
runs-on: depot-ubuntu-24.04
steps:
- name: Finalize API Tests status
env:
SHOULD_SKIP_WORKFLOW: ${{ needs.pre_job.outputs.should_skip }}
TESTS_CHANGED: ${{ needs.check-changes.outputs.api-changed }}
RUN_RESULT: ${{ needs.api-tests-run.result }}
SKIP_RESULT: ${{ needs.api-tests-skip.result }}
run: |
if [[ "$SHOULD_SKIP_WORKFLOW" == 'true' ]]; then
echo "API tests were skipped because this workflow run duplicated a successful or newer run."
exit 0
fi
if [[ "$TESTS_CHANGED" == 'true' ]]; then
if [[ "$RUN_RESULT" == 'success' ]]; then
echo "API tests ran successfully."
exit 0
fi
echo "API tests were required but finished with result: $RUN_RESULT" >&2
exit 1
fi
if [[ "$SKIP_RESULT" == 'success' ]]; then
echo "API tests were skipped because no API-related files changed."
exit 0
fi
echo "API tests were not required, but the skip job finished with result: $SKIP_RESULT" >&2
exit 1
cli-tests-run:
name: Run CLI Tests
needs:
- pre_job
- check-changes
if: needs.pre_job.outputs.should_skip != 'true' && needs.check-changes.outputs.cli-changed == 'true'
uses: ./.github/workflows/cli-tests.yml
secrets: inherit
cli-tests-skip:
name: Skip CLI Tests
needs:
- pre_job
- check-changes
if: needs.pre_job.outputs.should_skip != 'true' && needs.check-changes.outputs.cli-changed != 'true'
runs-on: depot-ubuntu-24.04
steps:
- name: Report skipped CLI tests
run: echo "No CLI-related changes detected; skipping CLI tests."
cli-tests:
name: CLI Tests
if: ${{ always() }}
needs:
- pre_job
- check-changes
- cli-tests-run
- cli-tests-skip
runs-on: depot-ubuntu-24.04
steps:
- name: Finalize CLI Tests status
env:
SHOULD_SKIP_WORKFLOW: ${{ needs.pre_job.outputs.should_skip }}
TESTS_CHANGED: ${{ needs.check-changes.outputs.cli-changed }}
RUN_RESULT: ${{ needs.cli-tests-run.result }}
SKIP_RESULT: ${{ needs.cli-tests-skip.result }}
run: |
if [[ "$SHOULD_SKIP_WORKFLOW" == 'true' ]]; then
echo "CLI tests were skipped because this workflow run duplicated a successful or newer run."
exit 0
fi
if [[ "$TESTS_CHANGED" == 'true' ]]; then
if [[ "$RUN_RESULT" == 'success' ]]; then
echo "CLI tests ran successfully."
exit 0
fi
echo "CLI tests were required but finished with result: $RUN_RESULT" >&2
exit 1
fi
if [[ "$SKIP_RESULT" == 'success' ]]; then
echo "CLI tests were skipped because no CLI-related files changed."
exit 0
fi
echo "CLI tests were not required, but the skip job finished with result: $SKIP_RESULT" >&2
exit 1
web-tests-run:
name: Run Web Tests
needs:
- pre_job
- check-changes
if: needs.pre_job.outputs.should_skip != 'true' && needs.check-changes.outputs.web-changed == 'true'
uses: ./.github/workflows/web-tests.yml
secrets: inherit
web-tests-skip:
name: Skip Web Tests
needs:
- pre_job
- check-changes
if: needs.pre_job.outputs.should_skip != 'true' && needs.check-changes.outputs.web-changed != 'true'
runs-on: depot-ubuntu-24.04
steps:
- name: Report skipped web tests
run: echo "No web-related changes detected; skipping web tests."
web-tests:
name: Web Tests
if: ${{ always() }}
needs:
- pre_job
- check-changes
- web-tests-run
- web-tests-skip
runs-on: depot-ubuntu-24.04
steps:
- name: Finalize Web Tests status
env:
SHOULD_SKIP_WORKFLOW: ${{ needs.pre_job.outputs.should_skip }}
TESTS_CHANGED: ${{ needs.check-changes.outputs.web-changed }}
RUN_RESULT: ${{ needs.web-tests-run.result }}
SKIP_RESULT: ${{ needs.web-tests-skip.result }}
run: |
if [[ "$SHOULD_SKIP_WORKFLOW" == 'true' ]]; then
echo "Web tests were skipped because this workflow run duplicated a successful or newer run."
exit 0
fi
if [[ "$TESTS_CHANGED" == 'true' ]]; then
if [[ "$RUN_RESULT" == 'success' ]]; then
echo "Web tests ran successfully."
exit 0
fi
echo "Web tests were required but finished with result: $RUN_RESULT" >&2
exit 1
fi
if [[ "$SKIP_RESULT" == 'success' ]]; then
echo "Web tests were skipped because no web-related files changed."
exit 0
fi
echo "Web tests were not required, but the skip job finished with result: $SKIP_RESULT" >&2
exit 1
web-e2e-run:
name: Run Web Full-Stack E2E
needs:
- pre_job
- check-changes
if: needs.pre_job.outputs.should_skip != 'true' && needs.check-changes.outputs.e2e-changed == 'true'
uses: ./.github/workflows/web-e2e.yml
secrets: inherit
web-e2e-skip:
name: Skip Web Full-Stack E2E
needs:
- pre_job
- check-changes
if: needs.pre_job.outputs.should_skip != 'true' && needs.check-changes.outputs.e2e-changed != 'true'
runs-on: depot-ubuntu-24.04
steps:
- name: Report skipped web full-stack e2e
run: echo "No E2E-related changes detected; skipping web full-stack E2E."
web-e2e:
name: Web Full-Stack E2E
if: ${{ always() }}
needs:
- pre_job
- check-changes
- web-e2e-run
- web-e2e-skip
runs-on: depot-ubuntu-24.04
steps:
- name: Finalize Web Full-Stack E2E status
env:
SHOULD_SKIP_WORKFLOW: ${{ needs.pre_job.outputs.should_skip }}
TESTS_CHANGED: ${{ needs.check-changes.outputs.e2e-changed }}
RUN_RESULT: ${{ needs.web-e2e-run.result }}
SKIP_RESULT: ${{ needs.web-e2e-skip.result }}
run: |
if [[ "$SHOULD_SKIP_WORKFLOW" == 'true' ]]; then
echo "Web full-stack E2E was skipped because this workflow run duplicated a successful or newer run."
exit 0
fi
if [[ "$TESTS_CHANGED" == 'true' ]]; then
if [[ "$RUN_RESULT" == 'success' ]]; then
echo "Web full-stack E2E ran successfully."
exit 0
fi
echo "Web full-stack E2E was required but finished with result: $RUN_RESULT" >&2
exit 1
fi
if [[ "$SKIP_RESULT" == 'success' ]]; then
echo "Web full-stack E2E was skipped because no E2E-related files changed."
exit 0
fi
echo "Web full-stack E2E was not required, but the skip job finished with result: $SKIP_RESULT" >&2
exit 1
style-check:
name: Style Check
needs: pre_job
if: needs.pre_job.outputs.should_skip != 'true'
uses: ./.github/workflows/style.yml
with:
base-rev: ${{ github.event.pull_request.base.sha || github.event.merge_group.base_sha }}
vdb-tests-run:
name: Run VDB Tests
needs:
- pre_job
- check-changes
if: needs.pre_job.outputs.should_skip != 'true' && needs.check-changes.outputs.vdb-changed == 'true'
uses: ./.github/workflows/vdb-tests.yml
vdb-tests-skip:
name: Skip VDB Tests
needs:
- pre_job
- check-changes
if: needs.pre_job.outputs.should_skip != 'true' && needs.check-changes.outputs.vdb-changed != 'true'
runs-on: depot-ubuntu-24.04
steps:
- name: Report skipped VDB tests
run: echo "No VDB-related changes detected; skipping VDB tests."
vdb-tests:
name: VDB Tests
if: ${{ always() }}
needs:
- pre_job
- check-changes
- vdb-tests-run
- vdb-tests-skip
runs-on: depot-ubuntu-24.04
steps:
- name: Finalize VDB Tests status
env:
SHOULD_SKIP_WORKFLOW: ${{ needs.pre_job.outputs.should_skip }}
TESTS_CHANGED: ${{ needs.check-changes.outputs.vdb-changed }}
RUN_RESULT: ${{ needs.vdb-tests-run.result }}
SKIP_RESULT: ${{ needs.vdb-tests-skip.result }}
run: |
if [[ "$SHOULD_SKIP_WORKFLOW" == 'true' ]]; then
echo "VDB tests were skipped because this workflow run duplicated a successful or newer run."
exit 0
fi
if [[ "$TESTS_CHANGED" == 'true' ]]; then
if [[ "$RUN_RESULT" == 'success' ]]; then
echo "VDB tests ran successfully."
exit 0
fi
echo "VDB tests were required but finished with result: $RUN_RESULT" >&2
exit 1
fi
if [[ "$SKIP_RESULT" == 'success' ]]; then
echo "VDB tests were skipped because no VDB-related files changed."
exit 0
fi
echo "VDB tests were not required, but the skip job finished with result: $SKIP_RESULT" >&2
exit 1
db-migration-test-run:
name: Run DB Migration Test
needs:
- pre_job
- check-changes
if: needs.pre_job.outputs.should_skip != 'true' && needs.check-changes.outputs.migration-changed == 'true'
uses: ./.github/workflows/db-migration-test.yml
db-migration-test-skip:
name: Skip DB Migration Test
needs:
- pre_job
- check-changes
if: needs.pre_job.outputs.should_skip != 'true' && needs.check-changes.outputs.migration-changed != 'true'
runs-on: depot-ubuntu-24.04
steps:
- name: Report skipped DB migration tests
run: echo "No migration-related changes detected; skipping DB migration tests."
db-migration-test:
name: DB Migration Test
if: ${{ always() }}
needs:
- pre_job
- check-changes
- db-migration-test-run
- db-migration-test-skip
runs-on: depot-ubuntu-24.04
steps:
- name: Finalize DB Migration Test status
env:
SHOULD_SKIP_WORKFLOW: ${{ needs.pre_job.outputs.should_skip }}
TESTS_CHANGED: ${{ needs.check-changes.outputs.migration-changed }}
RUN_RESULT: ${{ needs.db-migration-test-run.result }}
SKIP_RESULT: ${{ needs.db-migration-test-skip.result }}
run: |
if [[ "$SHOULD_SKIP_WORKFLOW" == 'true' ]]; then
echo "DB migration tests were skipped because this workflow run duplicated a successful or newer run."
exit 0
fi
if [[ "$TESTS_CHANGED" == 'true' ]]; then
if [[ "$RUN_RESULT" == 'success' ]]; then
echo "DB migration tests ran successfully."
exit 0
fi
echo "DB migration tests were required but finished with result: $RUN_RESULT" >&2
exit 1
fi
if [[ "$SKIP_RESULT" == 'success' ]]; then
echo "DB migration tests were skipped because no migration-related files changed."
exit 0
fi
echo "DB migration tests were not required, but the skip job finished with result: $SKIP_RESULT" >&2
exit 1
sandbox-runtime-tests-run:
name: Run Sandbox Runtime Tests
needs:
- pre_job
- check-changes
if: needs.pre_job.outputs.should_skip != 'true' && needs.check-changes.outputs.sandbox-runtime-changed == 'true'
uses: ./.github/workflows/sandbox-runtime-tests.yml
secrets: inherit
sandbox-runtime-tests-skip:
name: Skip Sandbox Runtime Tests
needs:
- pre_job
- check-changes
if: needs.pre_job.outputs.should_skip != 'true' && needs.check-changes.outputs.sandbox-runtime-changed != 'true'
runs-on: depot-ubuntu-24.04
steps:
- name: Report skipped sandbox runtime tests
run: echo "No sandbox-runtime-related changes detected; skipping sandbox runtime tests."
sandbox-runtime-tests:
name: Sandbox Runtime Tests
if: ${{ always() }}
needs:
- pre_job
- check-changes
- sandbox-runtime-tests-run
- sandbox-runtime-tests-skip
runs-on: depot-ubuntu-24.04
steps:
- name: Finalize Sandbox Runtime Tests status
env:
SHOULD_SKIP_WORKFLOW: ${{ needs.pre_job.outputs.should_skip }}
TESTS_CHANGED: ${{ needs.check-changes.outputs.sandbox-runtime-changed }}
RUN_RESULT: ${{ needs.sandbox-runtime-tests-run.result }}
SKIP_RESULT: ${{ needs.sandbox-runtime-tests-skip.result }}
run: |
if [[ "$SHOULD_SKIP_WORKFLOW" == 'true' ]]; then
echo "Sandbox runtime tests were skipped because this workflow run duplicated a successful or newer run."
exit 0
fi
if [[ "$TESTS_CHANGED" == 'true' ]]; then
if [[ "$RUN_RESULT" == 'success' ]]; then
echo "Sandbox runtime tests ran successfully."
exit 0
fi
echo "Sandbox runtime tests were required but finished with result: $RUN_RESULT" >&2
exit 1
fi
if [[ "$SKIP_RESULT" == 'success' ]]; then
echo "Sandbox runtime tests were skipped because no sandbox-runtime-related files changed."
exit 0
fi
echo "Sandbox runtime tests were not required, but the skip job finished with result: $SKIP_RESULT" >&2
exit 1
-78
View File
@@ -1,78 +0,0 @@
name: Post-Merge Checks
on:
push:
branches: ["main"]
permissions:
contents: read
concurrency:
group: post-merge-${{ github.sha }}
cancel-in-progress: false
jobs:
check-changes:
name: Check Changed Files
runs-on: depot-ubuntu-24.04
outputs:
external-e2e-changed: ${{ steps.changes.outputs.external_e2e }}
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- uses: dorny/paths-filter@7b450fff21473bca461d4b92ce414b9d0420d706 # v4.0.2
id: changes
with:
filters: |
external_e2e:
- 'e2e/features/agent-v2/**'
- 'e2e/features/step-definitions/agent-v2/**'
- 'e2e/features/support/**'
- 'e2e/fixtures/test-materials/**'
- 'e2e/scripts/**'
- 'e2e/support/**'
- 'e2e/cucumber.config.ts'
- 'e2e/package.json'
- 'e2e/test-env.ts'
- 'e2e/tsx-register.js'
- '.github/workflows/post-merge.yml'
- '.github/workflows/web-e2e.yml'
- '.github/actions/setup-web/**'
- 'dify-agent/**'
- 'dify-agent-runtime/**'
- 'api/clients/agent_backend/**'
- 'api/core/app/apps/agent_app/**'
- 'api/core/workflow/nodes/agent_v2/**'
- 'api/controllers/console/agent/**'
- 'api/services/agent/**'
- 'api/core/plugin/**'
- 'api/services/plugin/**'
- 'api/core/tools/**'
- 'api/services/tools/**'
- 'packages/contracts/generated/api/console/agent/**'
- 'packages/contracts/generated/api/console/orpc.gen.ts'
- 'web/features/agent-v2/**'
- 'web/app/(commonLayout)/agents/**'
- 'web/app/(commonLayout)/@detailSidebar/agents/**'
- 'web/app/(commonLayout)/roster/**'
- 'web/app/components/base/chat/chat/**'
- 'web/app/components/base/voice-input/**'
- 'web/app/components/workflow/nodes/agent-v2/**'
- 'web/i18n/en-US/agent-v-2.json'
- 'web/i18n/en-US/common.json'
- 'web/service/base.ts'
- 'web/service/client.ts'
- 'web/service/console-link.ts'
- 'web/service/console-openapi-url.ts'
- 'web/service/console-router-loader.ts'
- 'web/service/share.ts'
- 'web/package.json'
- 'pnpm-workspace.yaml'
external-e2e:
name: External Runtime E2E
needs: check-changes
if: needs.check-changes.outputs.external-e2e-changed == 'true'
uses: ./.github/workflows/web-e2e.yml
with:
run-external-runtime: true
secrets: inherit
-104
View File
@@ -1,104 +0,0 @@
name: Comment with Pyrefly Diff
on:
workflow_run:
workflows:
- Pyrefly Diff Check
types:
- completed
permissions: {}
jobs:
comment:
name: Comment PR with pyrefly diff
runs-on: depot-ubuntu-24.04
permissions:
actions: read
contents: read
issues: write
pull-requests: write
if: ${{ github.event.workflow_run.conclusion == 'success' && github.event.workflow_run.pull_requests[0].head.repo.full_name != github.repository }}
steps:
- name: Download pyrefly diff artifact
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const fs = require('fs');
const artifacts = await github.rest.actions.listWorkflowRunArtifacts({
owner: context.repo.owner,
repo: context.repo.repo,
run_id: ${{ github.event.workflow_run.id }},
});
const match = artifacts.data.artifacts.find((artifact) =>
artifact.name === 'pyrefly_diff'
);
if (!match) {
throw new Error('pyrefly_diff artifact not found');
}
const download = await github.rest.actions.downloadArtifact({
owner: context.repo.owner,
repo: context.repo.repo,
artifact_id: match.id,
archive_format: 'zip',
});
fs.writeFileSync('pyrefly_diff.zip', Buffer.from(download.data));
- name: Unzip artifact
run: unzip -o pyrefly_diff.zip
- name: Post comment
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const fs = require('fs');
let diff = fs.readFileSync('pyrefly_diff.txt', { encoding: 'utf8' });
let prNumber = null;
try {
prNumber = parseInt(fs.readFileSync('pr_number.txt', { encoding: 'utf8' }), 10);
} catch (err) {
// Fallback to workflow_run payload if artifact is missing or incomplete.
const prs = context.payload.workflow_run.pull_requests || [];
if (prs.length > 0 && prs[0].number) {
prNumber = prs[0].number;
}
}
if (!prNumber) {
throw new Error('PR number not found in artifact or workflow_run payload');
}
const MAX_CHARS = 65000;
if (diff.length > MAX_CHARS) {
diff = diff.slice(0, MAX_CHARS);
diff = diff.slice(0, diff.lastIndexOf('\\n'));
diff += '\\n\\n... (truncated) ...';
}
if (diff.trim()) {
const body = '### Pyrefly Diff\n<details>\n<summary>base → PR</summary>\n\n```diff\n' + diff + '\n```\n</details>';
const marker = '### Pyrefly Diff';
const { data: comments } = await github.rest.issues.listComments({
issue_number: prNumber,
owner: context.repo.owner,
repo: context.repo.repo,
});
const existing = comments.find((comment) => comment.body.startsWith(marker));
if (existing) {
await github.rest.issues.updateComment({
comment_id: existing.id,
owner: context.repo.owner,
repo: context.repo.repo,
body,
});
} else {
await github.rest.issues.createComment({
issue_number: prNumber,
owner: context.repo.owner,
repo: context.repo.repo,
body,
});
}
}
-128
View File
@@ -1,128 +0,0 @@
name: Pyrefly Diff Check
on:
pull_request:
paths:
- 'api/**/*.py'
permissions:
contents: read
jobs:
pyrefly-diff:
runs-on: depot-ubuntu-24.04
permissions:
contents: read
issues: write
pull-requests: write
steps:
- name: Checkout PR branch
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
- name: Setup Python & UV
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
with:
enable-cache: true
- name: Install dependencies
run: uv sync --project api --dev
- name: Prepare diagnostics extractor
run: |
git show ${{ github.event.pull_request.head.sha }}:api/libs/pyrefly_diagnostics.py > /tmp/pyrefly_diagnostics.py
- name: Run pyrefly on PR branch
run: |
uv run --directory api --dev pyrefly check 2>&1 \
| uv run --directory api python /tmp/pyrefly_diagnostics.py > /tmp/pyrefly_pr.txt || true
- name: Checkout base branch
run: git checkout ${{ github.base_ref }}
- name: Run pyrefly on base branch
run: |
uv run --directory api --dev pyrefly check 2>&1 \
| uv run --directory api python /tmp/pyrefly_diagnostics.py > /tmp/pyrefly_base.txt || true
- name: Compute diff
run: |
diff -u /tmp/pyrefly_base.txt /tmp/pyrefly_pr.txt > pyrefly_diff.txt || true
- name: Check if line counts match
id: line_count_check
run: |
base_lines=$(wc -l < /tmp/pyrefly_base.txt)
pr_lines=$(wc -l < /tmp/pyrefly_pr.txt)
if [ "$base_lines" -eq "$pr_lines" ]; then
echo "same=true" >> $GITHUB_OUTPUT
else
echo "same=false" >> $GITHUB_OUTPUT
fi
- name: Save PR number
run: |
echo ${{ github.event.pull_request.number }} > pr_number.txt
- name: Upload pyrefly diff
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: pyrefly_diff
path: |
pyrefly_diff.txt
pr_number.txt
- name: Comment PR with pyrefly diff
if: ${{ github.event.pull_request.head.repo.full_name == github.repository && steps.line_count_check.outputs.same == 'false' }}
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const fs = require('fs');
let diff = fs.readFileSync('pyrefly_diff.txt', { encoding: 'utf8' });
const prNumber = context.payload.pull_request.number;
const MAX_CHARS = 65000;
if (diff.length > MAX_CHARS) {
diff = diff.slice(0, MAX_CHARS);
diff = diff.slice(0, diff.lastIndexOf('\n'));
diff += '\n\n... (truncated) ...';
}
const body = diff.trim()
? [
'### Pyrefly Diff',
'<details>',
'<summary>base → PR</summary>',
'',
'```diff',
diff,
'```',
'</details>',
].join('\n')
: '### Pyrefly Diff\nNo changes detected.';
const marker = '### Pyrefly Diff';
const { data: comments } = await github.rest.issues.listComments({
issue_number: prNumber,
owner: context.repo.owner,
repo: context.repo.repo,
});
const existing = comments.find((comment) => comment.body.startsWith(marker));
if (existing) {
await github.rest.issues.updateComment({
comment_id: existing.id,
owner: context.repo.owner,
repo: context.repo.repo,
body,
});
} else {
await github.rest.issues.createComment({
issue_number: prNumber,
owner: context.repo.owner,
repo: context.repo.repo,
body,
});
}
@@ -1,118 +0,0 @@
name: Comment with Pyrefly Type Coverage
on:
workflow_run:
workflows:
- Pyrefly Type Coverage
types:
- completed
permissions: {}
jobs:
comment:
name: Comment PR with type coverage
runs-on: depot-ubuntu-24.04
permissions:
actions: read
contents: read
issues: write
pull-requests: write
if: ${{ github.event.workflow_run.conclusion == 'success' && github.event.workflow_run.pull_requests[0].head.repo.full_name != github.repository }}
steps:
- name: Checkout default branch (trusted code)
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: Setup Python & UV
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
with:
enable-cache: true
- name: Install dependencies
run: uv sync --project api --dev
- name: Download type coverage artifact
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const fs = require('fs');
const artifacts = await github.rest.actions.listWorkflowRunArtifacts({
owner: context.repo.owner,
repo: context.repo.repo,
run_id: ${{ github.event.workflow_run.id }},
});
const match = artifacts.data.artifacts.find((artifact) =>
artifact.name === 'pyrefly_type_coverage'
);
if (!match) {
throw new Error('pyrefly_type_coverage artifact not found');
}
const download = await github.rest.actions.downloadArtifact({
owner: context.repo.owner,
repo: context.repo.repo,
artifact_id: match.id,
archive_format: 'zip',
});
fs.writeFileSync('pyrefly_type_coverage.zip', Buffer.from(download.data));
- name: Unzip artifact
run: unzip -o pyrefly_type_coverage.zip
- name: Render coverage markdown from structured data
id: render
run: |
comment_body="$(uv run --directory api python libs/pyrefly_type_coverage.py \
--base "$GITHUB_WORKSPACE/base_report.json" \
< "$GITHUB_WORKSPACE/pr_report.json")"
{
echo "### Pyrefly Type Coverage"
echo ""
echo "$comment_body"
} > /tmp/type_coverage_comment.md
- name: Post comment
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const fs = require('fs');
const body = fs.readFileSync('/tmp/type_coverage_comment.md', { encoding: 'utf8' });
let prNumber = null;
try {
prNumber = parseInt(fs.readFileSync('pr_number.txt', { encoding: 'utf8' }), 10);
} catch (err) {
const prs = context.payload.workflow_run.pull_requests || [];
if (prs.length > 0 && prs[0].number) {
prNumber = prs[0].number;
}
}
if (!prNumber) {
throw new Error('PR number not found in artifact or workflow_run payload');
}
// Update existing comment if one exists, otherwise create new
const { data: comments } = await github.rest.issues.listComments({
issue_number: prNumber,
owner: context.repo.owner,
repo: context.repo.repo,
});
const marker = '### Pyrefly Type Coverage';
const existing = comments.find(c => c.body.startsWith(marker));
if (existing) {
await github.rest.issues.updateComment({
comment_id: existing.id,
owner: context.repo.owner,
repo: context.repo.repo,
body,
});
} else {
await github.rest.issues.createComment({
issue_number: prNumber,
owner: context.repo.owner,
repo: context.repo.repo,
body,
});
}
-124
View File
@@ -1,124 +0,0 @@
name: Pyrefly Type Coverage
on:
pull_request:
paths:
- 'api/**/*.py'
permissions:
contents: read
jobs:
pyrefly-type-coverage:
runs-on: depot-ubuntu-24.04
permissions:
contents: read
issues: write
pull-requests: write
steps:
- name: Checkout PR branch
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
- name: Setup Python & UV
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
with:
enable-cache: true
- name: Install dependencies
run: uv sync --project api --dev
- name: Run pyrefly report on PR branch
run: |
uv run --directory api --dev pyrefly report 2>/dev/null > /tmp/pyrefly_report_pr.tmp && \
mv /tmp/pyrefly_report_pr.tmp /tmp/pyrefly_report_pr.json || \
echo '{}' > /tmp/pyrefly_report_pr.json
- name: Save helper script from base branch
run: |
git show ${{ github.event.pull_request.base.sha }}:api/libs/pyrefly_type_coverage.py > /tmp/pyrefly_type_coverage.py 2>/dev/null \
|| cp api/libs/pyrefly_type_coverage.py /tmp/pyrefly_type_coverage.py
- name: Checkout base branch
run: git checkout ${{ github.base_ref }}
- name: Run pyrefly report on base branch
run: |
uv run --directory api --dev pyrefly report 2>/dev/null > /tmp/pyrefly_report_base.tmp && \
mv /tmp/pyrefly_report_base.tmp /tmp/pyrefly_report_base.json || \
echo '{}' > /tmp/pyrefly_report_base.json
- name: Generate coverage comparison
id: coverage
run: |
comment_body="$(uv run --directory api python /tmp/pyrefly_type_coverage.py \
--base /tmp/pyrefly_report_base.json \
< /tmp/pyrefly_report_pr.json)"
{
echo "### Pyrefly Type Coverage"
echo ""
echo "$comment_body"
} | tee -a "$GITHUB_STEP_SUMMARY" > /tmp/type_coverage_comment.md
# Save structured data for the fork-PR comment workflow
cp /tmp/pyrefly_report_pr.json pr_report.json
cp /tmp/pyrefly_report_base.json base_report.json
# Keep fork-PR comments correct while the trusted workflow_run job is
# still using the default-branch renderer, which resolves --base from api/.
cp /tmp/pyrefly_report_base.json api/base_report.json
- name: Save PR number
run: |
echo ${{ github.event.pull_request.number }} > pr_number.txt
- name: Upload type coverage artifact
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: pyrefly_type_coverage
path: |
pr_report.json
base_report.json
api/base_report.json
pr_number.txt
- name: Comment PR with type coverage
if: ${{ github.event.pull_request.head.repo.full_name == github.repository }}
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const fs = require('fs');
const marker = '### Pyrefly Type Coverage';
let body;
try {
body = fs.readFileSync('/tmp/type_coverage_comment.md', { encoding: 'utf8' });
} catch {
body = `${marker}\n\n_Coverage report unavailable._`;
}
const prNumber = context.payload.pull_request.number;
// Update existing comment if one exists, otherwise create new
const { data: comments } = await github.rest.issues.listComments({
issue_number: prNumber,
owner: context.repo.owner,
repo: context.repo.repo,
});
const existing = comments.find(c => c.body.startsWith(marker));
if (existing) {
await github.rest.issues.updateComment({
comment_id: existing.id,
owner: context.repo.owner,
repo: context.repo.repo,
body,
});
} else {
await github.rest.issues.createComment({
issue_number: prNumber,
owner: context.repo.owner,
repo: context.repo.repo,
body,
});
}
@@ -1,98 +0,0 @@
name: Sandbox Runtime Tests
on:
workflow_call:
permissions:
contents: read
concurrency:
group: sandbox-runtime-tests-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
sandbox-runtime-unit:
name: Sandbox Runtime Unit Tests
runs-on: depot-ubuntu-24.04
defaults:
run:
shell: bash
working-directory: dify-agent-runtime
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
persist-credentials: false
- name: Setup Go
uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5.5.0
with:
go-version-file: dify-agent-runtime/go.mod
cache-dependency-path: dify-agent-runtime/go.sum
- name: Run unit tests
run: go test -race -count=1 ./...
sandbox-runtime-lint:
name: Sandbox Runtime Lint
runs-on: depot-ubuntu-24.04
defaults:
run:
shell: bash
working-directory: dify-agent-runtime
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
persist-credentials: false
- name: Setup Go
uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5.5.0
with:
go-version-file: dify-agent-runtime/go.mod
cache-dependency-path: dify-agent-runtime/go.sum
- name: Run golangci-lint
uses: golangci/golangci-lint-action@4afd733a84b1f43292c63897423277bb7f4313a9 # v6.5.0
with:
working-directory: dify-agent-runtime
version: latest
sandbox-runtime-integration:
name: Sandbox Runtime Integration Tests
runs-on: depot-ubuntu-24.04
defaults:
run:
shell: bash
working-directory: dify-agent-runtime
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
persist-credentials: false
- name: Setup Go
uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5.5.0
with:
go-version-file: dify-agent-runtime/go.mod
cache-dependency-path: dify-agent-runtime/go.sum
- name: Build and start runtime
run: make integration-up
- name: Run integration tests
run: make integration-test
- name: Dump container logs on failure
if: failure()
run: make integration-logs || true
- name: Stop runtime container
if: always()
run: make integration-down
@@ -1,28 +0,0 @@
name: Semantic Pull Request
on:
pull_request:
types:
- opened
- edited
- reopened
- synchronize
merge_group:
branches: ["main"]
types: [checks_requested]
jobs:
lint:
name: Validate PR title
permissions:
pull-requests: read
runs-on: depot-ubuntu-24.04
steps:
- name: Complete merge group check
if: github.event_name == 'merge_group'
run: echo "Semantic PR title validation is handled on pull requests."
- name: Check title
if: github.event_name == 'pull_request'
uses: amannn/action-semantic-pull-request@48f256284bd46cdaab1048c3721360e808335d50 # v6.1.1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+5 -5
View File
@@ -12,19 +12,19 @@ on:
jobs:
stale:
runs-on: depot-ubuntu-24.04
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write
steps:
- uses: actions/stale@1e223db275d687790206a7acac4d1a11bd6fe629 # v10.4.0
- uses: actions/stale@v5
with:
days-before-issue-stale: 15
days-before-issue-close: 3
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-issue-message: "Closed due to inactivity. If you have any questions, you can reopen it."
stale-pr-message: "Closed due to inactivity. If you have any questions, you can reopen it."
stale-issue-message: "Close due to it's no longer active, if you have any questions, you can reopen it."
stale-pr-message: "Close due to it's no longer active, if you have any questions, you can reopen it."
stale-issue-label: 'no-issue-activity'
stale-pr-label: 'no-pr-activity'
any-of-labels: '🌚 invalid,🙋‍♂️ question,wont-fix,no-issue-activity,no-pr-activity,💪 enhancement,🤔 cant-reproduce,🙏 help wanted'
any-of-labels: 'duplicate,question,invalid,wontfix,no-issue-activity,no-pr-activity,enhancement,cant-reproduce,help-wanted'
+60 -130
View File
@@ -1,199 +1,133 @@
name: Style check
on:
workflow_call:
inputs:
base-rev:
required: true
type: string
pull_request:
branches:
- main
- plugins/beta
concurrency:
group: style-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
permissions:
checks: write
statuses: write
contents: read
jobs:
python-style:
name: Python Style
runs-on: depot-ubuntu-24.04
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
fetch-depth: 0
uses: actions/checkout@v4
- name: Check changed files
id: changed-files
uses: tj-actions/changed-files@9426d40962ed5378910ee2e21d5f8c6fcbf2dd96 # v47.0.6
uses: tj-actions/changed-files@v45
with:
files: |
api/**
scripts/ast_grep_guard.py
scripts/check_no_new_getattr.py
scripts/check_no_new_controller_sqlalchemy.py
scripts/lint_controller_sqlalchemy.py
scripts/ast_grep_rules/no_new_getattr.yml
scripts/ast_grep_rules/no_new_controller_sqlalchemy.yml
.github/workflows/style.yml
.github/workflows/main-ci.yml
- name: Setup UV and Python
- name: Setup Poetry and Python
if: steps.changed-files.outputs.any_changed == 'true'
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
with:
enable-cache: false
python-version: "3.12"
cache-dependency-glob: api/uv.lock
uses: ./.github/actions/setup-poetry
- name: Install dependencies
if: steps.changed-files.outputs.any_changed == 'true'
run: uv sync --project api --dev
run: poetry install -C api --only lint
- name: Run Import Linter
- name: Ruff check
if: steps.changed-files.outputs.any_changed == 'true'
run: uv run --directory api --dev lint-imports
- name: Run Response Contract Linter
if: steps.changed-files.outputs.any_changed == 'true'
run: uv run --project api --dev python api/dev/lint_response_contracts.py --fail-on-mismatch
- name: Run No New Getattr Guard
if: steps.changed-files.outputs.any_changed == 'true'
run: uv run --project api python scripts/check_no_new_getattr.py --base-rev "${{ inputs.base-rev }}"
- name: Run No New Controller SQLAlchemy Guard
if: steps.changed-files.outputs.any_changed == 'true'
run: uv run --project api python scripts/check_no_new_controller_sqlalchemy.py --base-rev "${{ inputs.base-rev }}"
- name: Run Type Checks
if: steps.changed-files.outputs.any_changed == 'true'
env:
PYREFLY_OUTPUT_FORMAT: github
run: make type-check-core
run: |
poetry run -C api ruff --version
poetry run -C api ruff check ./
poetry run -C api ruff format --check ./
- name: Dotenv check
if: steps.changed-files.outputs.any_changed == 'true'
run: uv run --project api dotenv-linter ./api/.env.example ./web/.env.example
run: poetry run -P api dotenv-linter ./api/.env.example ./web/.env.example
- name: Lint hints
if: failure()
run: echo "Please run 'dev/reformat' to fix the fixable linting errors."
web-style:
name: Web Style
runs-on: depot-ubuntu-24.04
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./web
permissions:
checks: write
pull-requests: read
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
uses: actions/checkout@v4
- name: Check changed files
id: changed-files
uses: tj-actions/changed-files@9426d40962ed5378910ee2e21d5f8c6fcbf2dd96 # v47.0.6
uses: tj-actions/changed-files@v45
with:
files: |
web/**
e2e/**
sdks/nodejs-client/**
packages/**
package.json
pnpm-lock.yaml
pnpm-workspace.yaml
.nvmrc
.github/workflows/style.yml
.github/actions/setup-web/**
files: web/**
- name: Setup web environment
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 10
run_install: false
- name: Setup NodeJS
uses: actions/setup-node@v4
if: steps.changed-files.outputs.any_changed == 'true'
uses: ./.github/actions/setup-web
with:
node-version: 20
cache: pnpm
cache-dependency-path: ./web/package.json
- name: Web tsslint
- name: Web dependencies
if: steps.changed-files.outputs.any_changed == 'true'
env:
NODE_OPTIONS: --max-old-space-size=4096
run: vp run lint:tss
run: pnpm install --frozen-lockfile
- name: Web dead code check
- name: Web style check
if: steps.changed-files.outputs.any_changed == 'true'
run: vp run knip
run: yarn run lint
- name: Web dead code check production
if: steps.changed-files.outputs.any_changed == 'true'
run: vp run knip:production
- name: Web production unused declarations check
if: steps.changed-files.outputs.any_changed == 'true'
run: vp run knip:production-unused-check
ts-common-style:
name: TS Common
runs-on: depot-ubuntu-24.04-4
permissions:
checks: write
pull-requests: read
docker-compose-template:
name: Docker Compose Template
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
uses: actions/checkout@v4
- name: Check changed files
id: changed-files
uses: tj-actions/changed-files@9426d40962ed5378910ee2e21d5f8c6fcbf2dd96 # v47.0.6
uses: tj-actions/changed-files@v45
with:
files: |
web/**
cli/**
e2e/**
sdks/nodejs-client/**
packages/**
package.json
pnpm-lock.yaml
pnpm-workspace.yaml
.nvmrc
vite.config.ts
lint.config.ts
eslint.config.mjs
oxlint-suppressions.json
eslint-suppressions.json
.vscode/**
.github/workflows/autofix.yml
.github/workflows/style.yml
.github/actions/setup-web/**
docker/generate_docker_compose
docker/.env.example
docker/docker-compose-template.yaml
docker/docker-compose.yaml
- name: Setup web environment
- name: Generate Docker Compose
if: steps.changed-files.outputs.any_changed == 'true'
uses: ./.github/actions/setup-web
run: |
cd docker
./generate_docker_compose
- name: Static check
- name: Check for changes
if: steps.changed-files.outputs.any_changed == 'true'
run: pnpm -w check
run: git diff --exit-code
superlinter:
name: SuperLinter
runs-on: depot-ubuntu-24.04
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
persist-credentials: false
uses: actions/checkout@v4
- name: Check changed files
id: changed-files
uses: tj-actions/changed-files@9426d40962ed5378910ee2e21d5f8c6fcbf2dd96 # v47.0.6
uses: tj-actions/changed-files@v45
with:
files: |
**.sh
@@ -201,16 +135,13 @@ jobs:
**.yml
**Dockerfile
dev/**
.editorconfig
- name: Super-linter
uses: super-linter/super-linter/slim@4ce20838b8ab83717e78138c5b3a1407148e0918 # v8.7.0
uses: super-linter/super-linter/slim@v7
if: steps.changed-files.outputs.any_changed == 'true'
env:
BASH_SEVERITY: warning
DEFAULT_BRANCH: origin/main
EDITORCONFIG_FILE_NAME: editorconfig-checker.json
FILTER_REGEX_INCLUDE: pnpm-lock.yaml
DEFAULT_BRANCH: plugins/beta
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
IGNORE_GENERATED_FILES: true
IGNORE_GITIGNORED_FILES: true
@@ -219,6 +150,5 @@ jobs:
# FIXME: temporarily disabled until api-docker.yaml's run script is fixed for shellcheck
# VALIDATE_GITHUB_ACTIONS: true
VALIDATE_DOCKERFILE_HADOLINT: true
VALIDATE_EDITORCONFIG: true
VALIDATE_XML: true
VALIDATE_YAML: true
+10 -11
View File
@@ -6,9 +6,6 @@ on:
- main
paths:
- sdks/**
- package.json
- pnpm-lock.yaml
- pnpm-workspace.yaml
concurrency:
group: sdk-tests-${{ github.head_ref || github.run_id }}
@@ -17,26 +14,28 @@ concurrency:
jobs:
build:
name: unit test for Node.js SDK
runs-on: depot-ubuntu-24.04
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16, 18, 20]
defaults:
run:
working-directory: sdks/nodejs-client
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
- uses: actions/checkout@v4
- name: Use Node.js
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: 22
node-version: ${{ matrix.node-version }}
cache: ''
cache-dependency-path: 'pnpm-lock.yaml'
- name: Install Dependencies
run: pnpm install --frozen-lockfile
run: pnpm install
- name: Test
run: pnpm test
@@ -0,0 +1,54 @@
name: Check i18n Files and Create PR
on:
pull_request:
types: [closed]
branches: [main]
jobs:
check-and-update:
if: github.event.pull_request.merged == true
runs-on: ubuntu-latest
defaults:
run:
working-directory: web
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 2 # last 2 commits
- name: Check for file changes in i18n/en-US
id: check_files
run: |
recent_commit_sha=$(git rev-parse HEAD)
second_recent_commit_sha=$(git rev-parse HEAD~1)
changed_files=$(git diff --name-only $recent_commit_sha $second_recent_commit_sha -- 'i18n/en-US/*.ts')
echo "Changed files: $changed_files"
if [ -n "$changed_files" ]; then
echo "FILES_CHANGED=true" >> $GITHUB_ENV
else
echo "FILES_CHANGED=false" >> $GITHUB_ENV
fi
- name: Set up Node.js
if: env.FILES_CHANGED == 'true'
uses: actions/setup-node@v2
with:
node-version: 'lts/*'
- name: Install dependencies
if: env.FILES_CHANGED == 'true'
run: pnpm install --frozen-lockfile
- name: Run npm script
if: env.FILES_CHANGED == 'true'
run: pnpm run auto-gen-i18n
- name: Create Pull Request
if: env.FILES_CHANGED == 'true'
uses: peter-evans/create-pull-request@v6
with:
commit-message: Update i18n files based on en-US changes
title: 'chore: translate i18n files'
body: This PR was automatically created to update i18n files based on changes in en-US locale.
branch: chore/automated-i18n-updates
-345
View File
@@ -1,345 +0,0 @@
name: Translate i18n Files with Claude Code
# Note: claude-code-action doesn't support push events directly.
# Push events are bridged by trigger-i18n-sync.yml via repository_dispatch.
on:
repository_dispatch:
types: [i18n-sync]
workflow_dispatch:
inputs:
files:
description: 'Specific files to translate (space-separated, e.g., "app common"). Required for full mode; leave empty in incremental mode to use en-US files changed since HEAD~1.'
required: false
type: string
languages:
description: 'Specific languages to translate (space-separated, e.g., "zh-Hans ja-JP"). Leave empty for all supported target languages except en-US.'
required: false
type: string
mode:
description: 'Sync mode: incremental (compare with previous en-US revision) or full (sync all keys in scope)'
required: false
default: incremental
type: choice
options:
- incremental
- full
permissions:
contents: write
pull-requests: write
concurrency:
group: translate-i18n-${{ github.event_name }}-${{ github.ref }}
cancel-in-progress: false
jobs:
translate:
if: github.repository == 'langgenius/dify'
runs-on: depot-ubuntu-24.04
timeout-minutes: 120
steps:
- name: Checkout repository
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
token: ${{ secrets.GITHUB_TOKEN }}
- name: Configure Git
run: |
git config --global user.name "github-actions[bot]"
git config --global user.email "github-actions[bot]@users.noreply.github.com"
- name: Setup web environment
uses: ./.github/actions/setup-web
- name: Prepare sync context
id: context
shell: bash
run: |
DEFAULT_TARGET_LANGS=$(awk "
/value: '/ {
value=\$2
gsub(/[',]/, \"\", value)
}
/supported: true/ && value != \"en-US\" {
printf \"%s \", value
}
" web/i18n-config/languages.ts | sed 's/[[:space:]]*$//')
generate_changes_json() {
node .github/scripts/generate-i18n-changes.mjs
}
if [ "${{ github.event_name }}" = "repository_dispatch" ]; then
BASE_SHA="${{ github.event.client_payload.base_sha }}"
HEAD_SHA="${{ github.event.client_payload.head_sha }}"
CHANGED_FILES="${{ github.event.client_payload.changed_files }}"
TARGET_LANGS="$DEFAULT_TARGET_LANGS"
SYNC_MODE="${{ github.event.client_payload.sync_mode || 'incremental' }}"
if [ -n "${{ github.event.client_payload.changes_base64 }}" ]; then
printf '%s' '${{ github.event.client_payload.changes_base64 }}' | base64 -d > /tmp/i18n-changes.json
CHANGES_AVAILABLE="true"
CHANGES_SOURCE="embedded"
elif [ -n "$BASE_SHA" ] && [ -n "$CHANGED_FILES" ]; then
export BASE_SHA HEAD_SHA CHANGED_FILES
generate_changes_json
CHANGES_AVAILABLE="true"
CHANGES_SOURCE="recomputed"
else
printf '%s' '{"baseSha":"","headSha":"","files":[],"changes":{}}' > /tmp/i18n-changes.json
CHANGES_AVAILABLE="false"
CHANGES_SOURCE="unavailable"
fi
else
BASE_SHA=""
HEAD_SHA=$(git rev-parse HEAD)
if [ -n "${{ github.event.inputs.languages }}" ]; then
TARGET_LANGS="${{ github.event.inputs.languages }}"
else
TARGET_LANGS="$DEFAULT_TARGET_LANGS"
fi
SYNC_MODE="${{ github.event.inputs.mode || 'incremental' }}"
if [ -n "${{ github.event.inputs.files }}" ]; then
CHANGED_FILES="${{ github.event.inputs.files }}"
elif [ "$SYNC_MODE" = "incremental" ]; then
BASE_SHA=$(git rev-parse HEAD~1 2>/dev/null || true)
if [ -n "$BASE_SHA" ]; then
CHANGED_FILES=$(git diff --name-only "$BASE_SHA" "$HEAD_SHA" -- 'web/i18n/en-US/*.json' 2>/dev/null | sed -n 's@^.*/@@p' | sed 's/\.json$//' | tr '\n' ' ' | sed 's/[[:space:]]*$//')
else
CHANGED_FILES=$(find web/i18n/en-US -maxdepth 1 -type f -name '*.json' -print | sed -n 's@^.*/@@p' | sed 's/\.json$//' | sort | tr '\n' ' ' | sed 's/[[:space:]]*$//')
fi
elif [ "$SYNC_MODE" = "full" ]; then
echo "workflow_dispatch full mode requires the files input to stay within CI limits." >&2
exit 1
else
CHANGED_FILES=""
fi
if [ "$SYNC_MODE" = "incremental" ] && [ -n "$CHANGED_FILES" ]; then
export BASE_SHA HEAD_SHA CHANGED_FILES
generate_changes_json
CHANGES_AVAILABLE="true"
CHANGES_SOURCE="local"
else
printf '%s' '{"baseSha":"","headSha":"","files":[],"changes":{}}' > /tmp/i18n-changes.json
CHANGES_AVAILABLE="false"
CHANGES_SOURCE="unavailable"
fi
fi
FILE_ARGS=""
if [ -n "$CHANGED_FILES" ]; then
FILE_ARGS="--file $CHANGED_FILES"
fi
LANG_ARGS=""
if [ -n "$TARGET_LANGS" ]; then
LANG_ARGS="--lang $TARGET_LANGS"
fi
{
echo "DEFAULT_TARGET_LANGS=$DEFAULT_TARGET_LANGS"
echo "BASE_SHA=$BASE_SHA"
echo "HEAD_SHA=$HEAD_SHA"
echo "CHANGED_FILES=$CHANGED_FILES"
echo "TARGET_LANGS=$TARGET_LANGS"
echo "SYNC_MODE=$SYNC_MODE"
echo "CHANGES_AVAILABLE=$CHANGES_AVAILABLE"
echo "CHANGES_SOURCE=$CHANGES_SOURCE"
echo "FILE_ARGS=$FILE_ARGS"
echo "LANG_ARGS=$LANG_ARGS"
} >> "$GITHUB_OUTPUT"
echo "Files: ${CHANGED_FILES:-<none>}"
echo "Languages: ${TARGET_LANGS:-<none>}"
echo "Mode: $SYNC_MODE"
- name: Run Claude Code for Translation Sync
if: steps.context.outputs.CHANGED_FILES != ''
uses: anthropics/claude-code-action@e90deca47693f9457b72f2b53c17d7c445a87342 # v1.0.171
with:
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
github_token: ${{ secrets.GITHUB_TOKEN }}
allowed_bots: 'github-actions[bot]'
show_full_output: ${{ github.event_name == 'workflow_dispatch' }}
prompt: |
You are the i18n sync agent for the Dify repository.
Your job is to keep translations synchronized with the English source files under `${{ github.workspace }}/web/i18n/en-US/`.
Use absolute paths at all times:
- Repo root: `${{ github.workspace }}`
- Web directory: `${{ github.workspace }}/web`
- Language config: `${{ github.workspace }}/web/i18n-config/languages.ts`
Inputs:
- Files in scope: `${{ steps.context.outputs.CHANGED_FILES }}`
- Target languages: `${{ steps.context.outputs.TARGET_LANGS }}`
- Sync mode: `${{ steps.context.outputs.SYNC_MODE }}`
- Base SHA: `${{ steps.context.outputs.BASE_SHA }}`
- Head SHA: `${{ steps.context.outputs.HEAD_SHA }}`
- Scoped file args: `${{ steps.context.outputs.FILE_ARGS }}`
- Scoped language args: `${{ steps.context.outputs.LANG_ARGS }}`
- Structured change set available: `${{ steps.context.outputs.CHANGES_AVAILABLE }}`
- Structured change set source: `${{ steps.context.outputs.CHANGES_SOURCE }}`
- Structured change set file: `/tmp/i18n-changes.json`
Tool rules:
- Use Read for repository files.
- Use Edit for JSON updates.
- Use Bash only for `vp`.
- Do not use Bash for `git`, `gh`, or branch management.
Required execution plan:
1. Resolve target languages.
- Use the provided `Target languages` value as the source of truth.
- If it is unexpectedly empty, read `${{ github.workspace }}/web/i18n-config/languages.ts` and use every language with `supported: true` except `en-US`.
2. Stay strictly in scope.
- Only process the files listed in `Files in scope`.
- Only process the resolved target languages, never `en-US`.
- Do not touch unrelated i18n files.
- Do not modify `${{ github.workspace }}/web/i18n/en-US/`.
3. Resolve source changes.
- If `Structured change set available` is `true`, read `/tmp/i18n-changes.json` and use it as the source of truth for file-level and key-level changes.
- For each file entry:
- `added` contains new English keys that need translations.
- `updated` contains stale keys whose English source changed; re-translate using the `after` value.
- `deleted` contains keys that should be removed from locale files.
- `fileDeleted: true` means the English file no longer exists; remove the matching locale file if present.
- Read the current English JSON file for any file that still exists so wording, placeholders, and surrounding terminology stay accurate.
- If `Structured change set available` is `false`, treat this as a scoped full sync and use the current English files plus scoped checks as the source of truth.
4. Run a scoped pre-check before editing:
- `vp run dify-web#i18n:check ${{ steps.context.outputs.FILE_ARGS }} ${{ steps.context.outputs.LANG_ARGS }}`
- Use this command as the source of truth for missing and extra keys inside the current scope.
5. Apply translations.
- For every target language and scoped file:
- If `fileDeleted` is `true`, remove the locale file if it exists and skip the rest of that file.
- If the locale file does not exist yet, create it with `Write` and then continue with `Edit` as needed.
- ADD missing keys.
- UPDATE stale translations when the English value changed.
- DELETE removed keys. Prefer `vp run dify-web#i18n:check ${{ steps.context.outputs.FILE_ARGS }} ${{ steps.context.outputs.LANG_ARGS }} --auto-remove` for extra keys so deletions stay in scope.
- Preserve placeholders exactly: `{{variable}}`, `${variable}`, HTML tags, component tags, and variable names.
- Match the existing terminology and register used by each locale.
- Prefer one Edit per file when stable, but prioritize correctness over batching.
6. Verify only the edited files.
- Run `vp fmt <repo-relative edited paths such as web/i18n/...>`
- Run `vp run dify-web#i18n:check ${{ steps.context.outputs.FILE_ARGS }} ${{ steps.context.outputs.LANG_ARGS }}`
- If verification fails, fix the remaining problems before continuing.
7. Stop after the scoped locale files are updated and verification passes.
- Do not create branches, commits, or pull requests.
claude_args: |
--max-turns 120
--allowedTools "Read,Write,Edit,Bash(vp *),Bash(vp:*),Glob,Grep"
- name: Prepare branch metadata
id: pr_meta
if: steps.context.outputs.CHANGED_FILES != ''
shell: bash
run: |
if [ -z "$(git -C "${{ github.workspace }}" status --porcelain -- web/i18n/)" ]; then
echo "has_changes=false" >> "$GITHUB_OUTPUT"
exit 0
fi
SCOPE_HASH=$(printf '%s|%s|%s' "${{ steps.context.outputs.CHANGED_FILES }}" "${{ steps.context.outputs.TARGET_LANGS }}" "${{ steps.context.outputs.SYNC_MODE }}" | sha256sum | cut -c1-8)
HEAD_SHORT=$(printf '%s' "${{ steps.context.outputs.HEAD_SHA }}" | cut -c1-12)
BRANCH_NAME="chore/i18n-sync-${HEAD_SHORT}-${SCOPE_HASH}"
{
echo "has_changes=true"
echo "branch_name=$BRANCH_NAME"
} >> "$GITHUB_OUTPUT"
- name: Commit translation changes
if: steps.pr_meta.outputs.has_changes == 'true'
shell: bash
run: |
git -C "${{ github.workspace }}" checkout -B "${{ steps.pr_meta.outputs.branch_name }}"
git -C "${{ github.workspace }}" add web/i18n/
git -C "${{ github.workspace }}" commit -m "chore(i18n): sync translations with en-US"
- name: Push translation branch
if: steps.pr_meta.outputs.has_changes == 'true'
shell: bash
run: |
if git -C "${{ github.workspace }}" ls-remote --exit-code --heads origin "${{ steps.pr_meta.outputs.branch_name }}" >/dev/null 2>&1; then
git -C "${{ github.workspace }}" push --force-with-lease origin "${{ steps.pr_meta.outputs.branch_name }}"
else
git -C "${{ github.workspace }}" push --set-upstream origin "${{ steps.pr_meta.outputs.branch_name }}"
fi
- name: Create or update translation PR
if: steps.pr_meta.outputs.has_changes == 'true'
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
BRANCH_NAME: ${{ steps.pr_meta.outputs.branch_name }}
FILES_IN_SCOPE: ${{ steps.context.outputs.CHANGED_FILES }}
TARGET_LANGS: ${{ steps.context.outputs.TARGET_LANGS }}
SYNC_MODE: ${{ steps.context.outputs.SYNC_MODE }}
CHANGES_SOURCE: ${{ steps.context.outputs.CHANGES_SOURCE }}
BASE_SHA: ${{ steps.context.outputs.BASE_SHA }}
HEAD_SHA: ${{ steps.context.outputs.HEAD_SHA }}
REPO_NAME: ${{ github.repository }}
shell: bash
run: |
PR_BODY_FILE=/tmp/i18n-pr-body.md
LANG_COUNT=$(printf '%s\n' "$TARGET_LANGS" | wc -w | tr -d ' ')
if [ "$LANG_COUNT" = "0" ]; then
LANG_COUNT="0"
fi
export LANG_COUNT
node <<'NODE' > "$PR_BODY_FILE"
const fs = require('node:fs')
const changesPath = '/tmp/i18n-changes.json'
const changes = fs.existsSync(changesPath)
? JSON.parse(fs.readFileSync(changesPath, 'utf8'))
: { changes: {} }
const filesInScope = (process.env.FILES_IN_SCOPE || '').split(/\s+/).filter(Boolean)
const lines = [
'## Summary',
'',
`- **Files synced**: \`${process.env.FILES_IN_SCOPE || '<none>'}\``,
`- **Languages updated**: ${process.env.TARGET_LANGS || '<none>'} (${process.env.LANG_COUNT} languages)`,
`- **Sync mode**: ${process.env.SYNC_MODE}${process.env.BASE_SHA ? ` (base: \`${process.env.BASE_SHA.slice(0, 10)}\`, head: \`${process.env.HEAD_SHA.slice(0, 10)}\`)` : ` (head: \`${process.env.HEAD_SHA.slice(0, 10)}\`)`}`,
'',
'### Key changes',
]
for (const fileName of filesInScope) {
const fileChange = changes.changes?.[fileName] || { added: {}, updated: {}, deleted: [], fileDeleted: false }
const addedKeys = Object.keys(fileChange.added || {})
const updatedKeys = Object.keys(fileChange.updated || {})
const deletedKeys = fileChange.deleted || []
lines.push(`- \`${fileName}\`: +${addedKeys.length} / ~${updatedKeys.length} / -${deletedKeys.length}${fileChange.fileDeleted ? ' (file deleted in en-US)' : ''}`)
}
lines.push(
'',
'## Verification',
'',
`- \`vp run dify-web#i18n:check --file ${process.env.FILES_IN_SCOPE} --lang ${process.env.TARGET_LANGS}\``,
`- \`vp fmt <repo-relative edited paths such as web/i18n/...>\``,
'',
'## Notes',
'',
'- This PR was generated from structured en-US key changes produced by `trigger-i18n-sync.yml`.',
`- Structured change source: ${process.env.CHANGES_SOURCE || 'unknown'}.`,
'- Branch name is deterministic for the head SHA and scope, so reruns update the same PR instead of opening duplicates.',
'',
'🤖 Generated with [Claude Code](https://claude.com/claude-code)'
)
process.stdout.write(lines.join('\n'))
NODE
EXISTING_PR_NUMBER=$(gh pr list --repo "$REPO_NAME" --head "$BRANCH_NAME" --state open --json number --jq '.[0].number')
if [ -n "$EXISTING_PR_NUMBER" ] && [ "$EXISTING_PR_NUMBER" != "null" ]; then
gh pr edit "$EXISTING_PR_NUMBER" --repo "$REPO_NAME" --title "chore(i18n): sync translations with en-US" --body-file "$PR_BODY_FILE"
else
gh pr create --repo "$REPO_NAME" --head "$BRANCH_NAME" --base main --title "chore(i18n): sync translations with en-US" --body-file "$PR_BODY_FILE"
fi
-90
View File
@@ -1,90 +0,0 @@
name: Trigger i18n Sync on Push
on:
push:
branches: [main]
paths:
- 'web/i18n/en-US/*.json'
permissions:
contents: write
concurrency:
group: trigger-i18n-sync-${{ github.ref }}
cancel-in-progress: true
jobs:
trigger:
if: github.repository == 'langgenius/dify'
runs-on: depot-ubuntu-24.04
timeout-minutes: 5
steps:
- name: Checkout repository
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
- name: Detect changed files and build structured change set
id: detect
shell: bash
run: |
BASE_SHA="${{ github.event.before }}"
if [ -z "$BASE_SHA" ] || [ "$BASE_SHA" = "0000000000000000000000000000000000000000" ]; then
BASE_SHA=$(git rev-parse HEAD~1 2>/dev/null || true)
fi
HEAD_SHA="${{ github.sha }}"
if [ -n "$BASE_SHA" ]; then
CHANGED_FILES=$(git diff --name-only "$BASE_SHA" "$HEAD_SHA" -- 'web/i18n/en-US/*.json' 2>/dev/null | sed -n 's@^.*/@@p' | sed 's/\.json$//' | tr '\n' ' ' | sed 's/[[:space:]]*$//')
else
CHANGED_FILES=$(find web/i18n/en-US -maxdepth 1 -type f -name '*.json' -print | sed -n 's@^.*/@@p' | sed 's/\.json$//' | sort | tr '\n' ' ' | sed 's/[[:space:]]*$//')
fi
export BASE_SHA HEAD_SHA CHANGED_FILES
node .github/scripts/generate-i18n-changes.mjs
if [ -n "$CHANGED_FILES" ]; then
echo "has_changes=true" >> "$GITHUB_OUTPUT"
else
echo "has_changes=false" >> "$GITHUB_OUTPUT"
fi
echo "base_sha=$BASE_SHA" >> "$GITHUB_OUTPUT"
echo "head_sha=$HEAD_SHA" >> "$GITHUB_OUTPUT"
echo "changed_files=$CHANGED_FILES" >> "$GITHUB_OUTPUT"
- name: Trigger i18n sync workflow
if: steps.detect.outputs.has_changes == 'true'
uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0
env:
BASE_SHA: ${{ steps.detect.outputs.base_sha }}
HEAD_SHA: ${{ steps.detect.outputs.head_sha }}
CHANGED_FILES: ${{ steps.detect.outputs.changed_files }}
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const fs = require('fs')
const changesJson = fs.readFileSync('/tmp/i18n-changes.json', 'utf8')
const changesBase64 = Buffer.from(changesJson).toString('base64')
const maxEmbeddedChangesChars = 48000
const changesEmbedded = changesBase64.length <= maxEmbeddedChangesChars
if (!changesEmbedded) {
console.log(`Structured change set too large to embed safely (${changesBase64.length} chars). Downstream workflow will regenerate it from git history.`)
}
await github.rest.repos.createDispatchEvent({
owner: context.repo.owner,
repo: context.repo.repo,
event_type: 'i18n-sync',
client_payload: {
changed_files: process.env.CHANGED_FILES,
changes_base64: changesEmbedded ? changesBase64 : '',
changes_embedded: changesEmbedded,
sync_mode: 'incremental',
base_sha: process.env.BASE_SHA,
head_sha: process.env.HEAD_SHA,
},
})
-68
View File
@@ -1,68 +0,0 @@
name: Run Full VDB Tests
on:
schedule:
- cron: '0 3 * * 1'
workflow_dispatch:
permissions:
contents: read
concurrency:
group: vdb-tests-full-${{ github.ref || github.run_id }}
cancel-in-progress: true
jobs:
test:
name: Full VDB Tests
if: github.repository == 'langgenius/dify'
runs-on: depot-ubuntu-24.04
strategy:
matrix:
python-version:
- "3.12"
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
- name: Free Disk Space
uses: endersonmenezes/free-disk-space@7901478139cff6e9d44df5972fd8ab8fcade4db1 # v3.2.2
with:
remove_dotnet: true
remove_haskell: true
remove_tool_cache: true
- name: Setup UV and Python
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
with:
enable-cache: true
python-version: ${{ matrix.python-version }}
cache-dependency-glob: api/uv.lock
- name: Check UV lockfile
run: uv lock --project api --check
- name: Install dependencies
run: uv sync --project api --dev
# - name: Set up Vector Store (TiDB)
# uses: hoverkraft-tech/compose-action@v2.0.2
# with:
# compose-file: docker/tidb/docker-compose.yaml
# services: |
# tidb
# tiflash
# - name: Check VDB Ready (TiDB)
# run: uv run --project api python api/providers/vdb/tidb-vector/tests/integration_tests/check_tiflash_ready.py
- name: Test Vector Stores
run: |
uv run --project api pytest \
--start-vdb \
--vdb-services "weaviate,qdrant,couchbase-server,etcd,minio,milvus-standalone,pgvecto-rs,pgvector,chroma,elasticsearch,oceanbase" \
--timeout "${PYTEST_TIMEOUT:-180}" \
api/providers/vdb/*/tests/integration_tests
+47 -41
View File
@@ -1,10 +1,15 @@
name: Run VDB Smoke Tests
name: Run VDB Tests
on:
workflow_call:
permissions:
contents: read
pull_request:
branches:
- main
paths:
- api/core/rag/datasource/**
- docker/**
- .github/workflows/vdb-tests.yml
- api/poetry.lock
- api/pyproject.toml
concurrency:
group: vdb-tests-${{ github.head_ref || github.run_id }}
@@ -12,56 +17,57 @@ concurrency:
jobs:
test:
name: VDB Smoke Tests
runs-on: depot-ubuntu-24.04
name: VDB Tests
runs-on: ubuntu-latest
strategy:
matrix:
python-version:
- "3.11"
- "3.12"
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
uses: actions/checkout@v4
- name: Free Disk Space
uses: endersonmenezes/free-disk-space@7901478139cff6e9d44df5972fd8ab8fcade4db1 # v3.2.2
- name: Setup Poetry and Python ${{ matrix.python-version }}
uses: ./.github/actions/setup-poetry
with:
remove_dotnet: true
remove_haskell: true
remove_tool_cache: true
- name: Setup UV and Python
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
with:
enable-cache: true
python-version: ${{ matrix.python-version }}
cache-dependency-glob: api/uv.lock
poetry-lockfile: api/poetry.lock
- name: Check UV lockfile
run: uv lock --project api --check
- name: Check Poetry lockfile
run: |
poetry check -C api --lock
poetry show -C api
- name: Install dependencies
run: uv sync --project api --dev
run: poetry install -C api --with dev
# - name: Set up Vector Store (TiDB)
# uses: hoverkraft-tech/compose-action@v2.0.2
# with:
# compose-file: docker/tidb/docker-compose.yaml
# services: |
# tidb
# tiflash
- name: Set up dotenvs
run: |
cp docker/.env.example docker/.env
cp docker/middleware.env.example docker/middleware.env
# - name: Check VDB Ready (TiDB)
# run: uv run --project api python api/providers/vdb/tidb-vector/tests/integration_tests/check_tiflash_ready.py
- name: Expose Service Ports
run: sh .github/workflows/expose_service_ports.sh
- name: Set up Vector Stores (TiDB, Weaviate, Qdrant, PGVector, Milvus, PgVecto-RS, Chroma, MyScale, ElasticSearch, Couchbase)
uses: hoverkraft-tech/compose-action@v2.0.2
with:
compose-file: |
docker/docker-compose.yaml
services: |
weaviate
qdrant
couchbase-server
etcd
minio
milvus-standalone
pgvecto-rs
pgvector
chroma
elasticsearch
tidb
- name: Test Vector Stores
run: |
uv run --project api pytest \
--start-vdb \
--timeout "${PYTEST_TIMEOUT:-180}" \
api/providers/vdb/vdb-chroma/tests/integration_tests \
api/providers/vdb/vdb-pgvector/tests/integration_tests \
api/providers/vdb/vdb-qdrant/tests/integration_tests \
api/providers/vdb/vdb-weaviate/tests/integration_tests
run: poetry run -P api bash dev/pytest/pytest_vdb.sh
-195
View File
@@ -1,195 +0,0 @@
name: Web Full-Stack E2E
on:
workflow_call:
inputs:
run-external-runtime:
required: false
type: boolean
default: false
permissions:
contents: read
concurrency:
group: web-e2e-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
test:
name: Web Full-Stack E2E
runs-on: depot-ubuntu-24.04-4
timeout-minutes: 120
defaults:
run:
shell: bash
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
- name: Setup web dependencies
uses: ./.github/actions/setup-web
- name: Setup UV and Python
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
with:
enable-cache: true
python-version: "3.12"
cache-dependency-glob: |
api/uv.lock
dify-agent/uv.lock
- name: Install API dependencies
run: uv sync --project api --dev
- name: Run E2E support unit tests
working-directory: ./e2e
run: vp run test:unit
- name: Install Playwright browser
working-directory: ./e2e
run: vp run e2e:install
- name: Run isolated source-api and built-web Cucumber E2E tests
working-directory: ./e2e
env:
E2E_ADMIN_EMAIL: e2e-admin@example.com
E2E_ADMIN_NAME: E2E Admin
E2E_ADMIN_PASSWORD: E2eAdmin12345
E2E_FORCE_WEB_BUILD: "1"
E2E_INIT_PASSWORD: E2eInit12345
run: vp run e2e:full
- name: Preserve Chromium E2E report and logs
if: ${{ !cancelled() }}
run: |
if [[ -d e2e/cucumber-report ]]; then
mv e2e/cucumber-report e2e/cucumber-report-non-external
fi
if [[ -d e2e/.logs ]]; then
mv e2e/.logs e2e/.logs-non-external
fi
- name: Run WebKit keyboard and browser smoke tests
working-directory: ./e2e
env:
E2E_ADMIN_EMAIL: e2e-admin@example.com
E2E_ADMIN_NAME: E2E Admin
E2E_ADMIN_PASSWORD: E2eAdmin12345
E2E_BROWSER: webkit
E2E_INIT_PASSWORD: E2eInit12345
run: |
teardown_webkit_smoke() {
local run_status=$?
trap - EXIT
if ! vp run e2e:middleware:down; then
echo "::error title=E2E teardown failed::WebKit smoke middleware did not shut down cleanly."
if [[ "$run_status" -eq 0 ]]; then
run_status=1
fi
fi
exit "$run_status"
}
trap teardown_webkit_smoke EXIT
vp run e2e:middleware:up
vp run e2e -- --tags '@browser-smoke'
- name: Preserve WebKit E2E report and logs
if: ${{ !cancelled() }}
run: |
if [[ -d e2e/cucumber-report ]]; then
mv e2e/cucumber-report e2e/cucumber-report-webkit
fi
if [[ -d e2e/.logs ]]; then
mv e2e/.logs e2e/.logs-webkit
fi
- name: Run prepared and external runtime E2E tests
if: ${{ inputs.run-external-runtime }}
working-directory: ./e2e
env:
E2E_ADMIN_EMAIL: e2e-admin@example.com
E2E_ADMIN_NAME: E2E Admin
E2E_ADMIN_PASSWORD: E2eAdmin12345
E2E_AGENT_DECISION_MODEL_NAME: ${{ vars.E2E_AGENT_DECISION_MODEL_NAME || 'gpt-5.5' }}
E2E_AGENT_DECISION_MODEL_PROVIDER: ${{ vars.E2E_AGENT_DECISION_MODEL_PROVIDER || 'openai' }}
E2E_AGENT_DECISION_MODEL_TYPE: ${{ vars.E2E_AGENT_DECISION_MODEL_TYPE || 'llm' }}
E2E_FORCE_WEB_BUILD: "1"
E2E_INIT_PASSWORD: E2eInit12345
E2E_MARKETPLACE_API_URL: ${{ vars.E2E_MARKETPLACE_API_URL }}
E2E_MARKETPLACE_PLUGIN_IDS: ${{ vars.E2E_MARKETPLACE_PLUGIN_IDS }}
E2E_MODEL_PROVIDER_CREDENTIALS_JSON: ${{ secrets.E2E_MODEL_PROVIDER_CREDENTIALS_JSON }}
E2E_SPEECH_TO_TEXT_MODEL_NAME: ${{ vars.E2E_SPEECH_TO_TEXT_MODEL_NAME || 'gpt-4o-mini-transcribe' }}
E2E_SPEECH_TO_TEXT_MODEL_PROVIDER: ${{ vars.E2E_SPEECH_TO_TEXT_MODEL_PROVIDER || 'openai' }}
E2E_START_AGENT_BACKEND: ${{ vars.E2E_START_AGENT_BACKEND || '1' }}
E2E_STABLE_MODEL_NAME: ${{ vars.E2E_STABLE_MODEL_NAME || 'gpt-5-nano' }}
E2E_STABLE_MODEL_PROVIDER: ${{ vars.E2E_STABLE_MODEL_PROVIDER || 'openai' }}
E2E_STABLE_MODEL_TYPE: ${{ vars.E2E_STABLE_MODEL_TYPE || 'llm' }}
run: |
if [[ -z "${E2E_MODEL_PROVIDER_CREDENTIALS_JSON}" ]]; then
echo "E2E_MODEL_PROVIDER_CREDENTIALS_JSON is required for external runtime E2E." >&2
exit 1
fi
if [[ -d cucumber-report ]]; then
rm -rf cucumber-report-non-external
mv cucumber-report cucumber-report-non-external
fi
if [[ -d .logs ]]; then
rm -rf .logs-non-external
mv .logs .logs-non-external
fi
teardown_external_runtime() {
local run_status=$?
trap - EXIT
if ! vp run e2e:middleware:down; then
echo "::error title=E2E teardown failed::External runtime middleware did not shut down cleanly."
if [[ "$run_status" -eq 0 ]]; then
run_status=1
fi
fi
exit "$run_status"
}
trap teardown_external_runtime EXIT
vp run e2e:middleware:up
vp run e2e:post-merge:prepare
vp run e2e:post-merge
- name: Upload Cucumber report
if: ${{ !cancelled() }}
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: cucumber-report
path: |
e2e/cucumber-report
e2e/cucumber-report-non-external
e2e/cucumber-report-webkit
retention-days: 7
- name: Upload E2E logs
if: ${{ !cancelled() }}
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: e2e-logs
path: |
e2e/.logs/*.log
e2e/.logs-non-external/*.log
e2e/.logs-webkit/*.log
include-hidden-files: true
retention-days: 7
- name: Upload E2E seed report
if: ${{ !cancelled() && inputs.run-external-runtime }}
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: e2e-seed-report
path: e2e/seed-report
if-no-files-found: ignore
retention-days: 7
+27 -129
View File
@@ -1,13 +1,11 @@
name: Web Tests
on:
workflow_call:
secrets:
CODECOV_TOKEN:
required: false
permissions:
contents: read
pull_request:
branches:
- main
paths:
- web/**
concurrency:
group: web-tests-${{ github.head_ref || github.run_id }}
@@ -15,134 +13,34 @@ concurrency:
jobs:
test:
name: Web Tests (${{ matrix.shardIndex }}/${{ matrix.shardTotal }})
runs-on: depot-ubuntu-24.04-4
env:
VITEST_COVERAGE_SCOPE: app-components
strategy:
fail-fast: false
matrix:
shardIndex: [1, 2, 3, 4]
shardTotal: [4]
name: Web Tests
runs-on: ubuntu-latest
defaults:
run:
shell: bash
working-directory: ./web
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
uses: actions/checkout@v4
- name: Setup web environment
uses: ./.github/actions/setup-web
- name: Check changed files
id: changed-files
uses: tj-actions/changed-files@v45
with:
files: web/**
- name: Setup Node.js
uses: actions/setup-node@v4
if: steps.changed-files.outputs.any_changed == 'true'
with:
node-version: 20
cache: pnpm
cache-dependency-path: ./web/package.json
- name: Install dependencies
if: steps.changed-files.outputs.any_changed == 'true'
run: pnpm install --frozen-lockfile
- name: Run tests
run: vp test run --reporter=blob --reporter=minimal --shard=${{ matrix.shardIndex }}/${{ matrix.shardTotal }} --coverage
- name: Upload blob report
if: ${{ !cancelled() }}
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: blob-report-${{ matrix.shardIndex }}
path: web/.vitest-reports/*
include-hidden-files: true
retention-days: 1
merge-reports:
name: Merge Test Reports
if: ${{ !cancelled() }}
needs: [test]
runs-on: depot-ubuntu-24.04-4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
defaults:
run:
shell: bash
working-directory: ./web
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
- name: Setup web environment
uses: ./.github/actions/setup-web
- name: Download blob reports
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
with:
path: web/.vitest-reports
pattern: blob-report-*
merge-multiple: true
- name: Merge reports
run: vp test --merge-reports --coverage --silent=passed-only
- name: Report coverage
if: ${{ env.CODECOV_TOKEN != '' }}
uses: codecov/codecov-action@fb8b3582c8e4def4969c97caa2f19720cb33a72f # v7.0.0
with:
directory: web/coverage
flags: web
env:
CODECOV_TOKEN: ${{ env.CODECOV_TOKEN }}
dify-ui-test:
name: dify-ui Tests
runs-on: depot-ubuntu-24.04-4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
defaults:
run:
shell: bash
working-directory: ./packages/dify-ui
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
- name: Setup web environment
uses: ./.github/actions/setup-web
- name: Install Chromium for Browser Mode
run: vp exec playwright install --with-deps chromium
- name: Run dify-ui tests
run: vp test run --project unit --coverage --silent=passed-only
- name: Report coverage
if: ${{ env.CODECOV_TOKEN != '' }}
uses: codecov/codecov-action@fb8b3582c8e4def4969c97caa2f19720cb33a72f # v7.0.0
with:
directory: packages/dify-ui/coverage
flags: dify-ui
env:
CODECOV_TOKEN: ${{ env.CODECOV_TOKEN }}
dify-ui-storybook-test:
name: dify-ui Storybook Tests
runs-on: depot-ubuntu-24.04-4
defaults:
run:
shell: bash
working-directory: ./packages/dify-ui
steps:
- name: Checkout code
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
persist-credentials: false
- name: Setup web environment
uses: ./.github/actions/setup-web
- name: Install Chromium for Browser Mode
run: vp exec playwright install --with-deps chromium
- name: Run dify-ui Storybook tests
run: vp run test:storybook
if: steps.changed-files.outputs.any_changed == 'true'
run: pnpm test
+5 -70
View File
@@ -6,9 +6,6 @@ __pycache__/
# C extensions
*.so
# *db files
*.db
# Distribution / packaging
.Python
build/
@@ -49,7 +46,6 @@ htmlcov/
.cache
nosetests.xml
coverage.xml
coverage.json
*.cover
*.py,cover
.hypothesis/
@@ -100,7 +96,6 @@ __pypackages__/
# Celery stuff
celerybeat-schedule
celerybeat-schedule.db
celerybeat.pid
# SageMath parsed files
@@ -108,19 +103,12 @@ celerybeat.pid
# Environments
.env
.env-local
.venv
env/
venv/
ENV/
env.bak/
venv.bak/
# cli/ has a src/env/ module (DIFY_* registry) — don't treat it as a venv
!/cli/src/env/
!/cli/src/commands/env/
# cli/scripts/lib/ holds TS build helpers (resolve-buildinfo etc.) — don't treat as Python lib/
!/cli/scripts/lib/
.conda/
# Spyder project settings
@@ -133,18 +121,17 @@ venv.bak/
# mkdocs documentation
/site
# type checking
# mypy
.mypy_cache/
.dmypy.json
dmypy.json
pyrightconfig.json
!api/pyrightconfig.json
# Pyre type checker
.pyre/
.idea/'
.DS_Store
web/.vscode/settings.json
# Intellij IDEA Files
.idea/*
@@ -176,7 +163,6 @@ docker/volumes/db/data/*
docker/volumes/redis/data/*
docker/volumes/weaviate/*
docker/volumes/qdrant/*
docker/tidb/volumes/*
docker/volumes/etcd/*
docker/volumes/minio/*
docker/volumes/milvus/*
@@ -190,78 +176,27 @@ docker/volumes/pgvecto_rs/data/*
docker/volumes/couchbase/*
docker/volumes/oceanbase/*
docker/volumes/plugin_daemon/*
docker/volumes/matrixone/*
docker/volumes/mysql/*
docker/volumes/seekdb/*
!docker/volumes/oceanbase/init.d
docker/volumes/iris/*
docker/nginx/conf.d/default.conf
docker/nginx/ssl/*
!docker/nginx/ssl/.gitkeep
docker/middleware.env
docker/docker-compose.override.yaml
docker/env-backup/*
sdks/python-client/build
sdks/python-client/dist
sdks/python-client/dify_client.egg-info
.vscode/*
!.vscode/launch.json.template
!.vscode/settings.example.json
!.vscode/README.md
!.vscode/launch.json
pyrightconfig.json
api/.vscode
# vscode Code History Extension
.history
.eslintcache
.idea/
.vscode
# pnpm
/.pnpm-store
node_modules
.vite-hooks/_
# plugin migrate
plugins.jsonl
# generated API OpenAPI specs
packages/contracts/openapi/
# mise
mise.toml
# AI Assistant
.roo/
/.claude/worktrees/
api/.env.backup
/clickzetta
# Benchmark
scripts/stress-test/setup/config/
scripts/stress-test/reports/
# mcp
.playwright-mcp/
.serena/
# vitest browser mode attachments (failure screenshots, traces, etc.)
.vitest-attachments/
**/__screenshots__/
# settings
*.local.json
*.local.md
*.local.toml
# Code Agent Folder
.qoder/*
.context/
# Vitest local reports
web/.vitest-reports/
# dify-agent-runtime
dify-agent-runtime/bin/
dify-agent-runtime/.integration-state
-1
View File
@@ -1 +0,0 @@
22
-64
View File
@@ -1,64 +0,0 @@
#!/bin/sh
# get the list of modified files
files=$(git diff --cached --name-only)
# check if api or web directory is modified
api_modified=false
web_modified=false
skip_web_checks=false
git_path() {
git rev-parse --git-path "$1"
}
if [ -f "$(git_path MERGE_HEAD)" ] || \
[ -f "$(git_path CHERRY_PICK_HEAD)" ] || \
[ -f "$(git_path REVERT_HEAD)" ] || \
[ -f "$(git_path SQUASH_MSG)" ] || \
[ -d "$(git_path rebase-merge)" ] || \
[ -d "$(git_path rebase-apply)" ]; then
skip_web_checks=true
fi
for file in $files
do
# Use POSIX compliant pattern matching
case "$file" in
api/*.py)
# set api_modified flag to true
api_modified=true
;;
web/*)
# set web_modified flag to true
web_modified=true
;;
esac
done
# run linters based on the modified modules
if $api_modified; then
echo "Running Ruff linter on api module"
# run Ruff linter auto-fixing
uv run --project api --dev ruff check --fix ./api
# run Ruff linter checks
uv run --project api --dev ruff check ./api || status=$?
status=${status:-0}
if [ $status -ne 0 ]; then
echo "Ruff linter on api module error, exit code: $status"
echo "Please run 'dev/reformat' to fix the fixable linting errors."
exit 1
fi
fi
if $skip_web_checks; then
echo "Git operation in progress, skipping web checks"
exit 0
fi
vp staged
-14
View File
@@ -1,14 +0,0 @@
# Debugging with VS Code
This `launch.json.template` file provides various debug configurations for the Dify project within VS Code / Cursor. To use these configurations, you should copy the contents of this file into a new file named `launch.json` in the same `.vscode` directory.
## How to Use
1. **Create `launch.json`**: If you don't have one, create a file named `launch.json` inside the `.vscode` directory.
1. **Copy Content**: Copy the entire content from `launch.json.template` into your newly created `launch.json` file.
1. **Select Debug Configuration**: Go to the Run and Debug view in VS Code / Cursor (Ctrl+Shift+D or Cmd+Shift+D).
1. **Start Debugging**: Select the desired configuration from the dropdown menu and click the green play button.
## Tips
- If you need to debug with Edge browser instead of Chrome, modify the `serverReadyAction` configuration in the "Next.js: debug full stack" section, change `"debugWithChrome"` to `"debugWithEdge"` to use Microsoft Edge for debugging.
-40
View File
@@ -1,40 +0,0 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "Python: API (gevent)",
"type": "debugpy",
"request": "launch",
"module": "gevent.monkey",
"args": ["--module", "app"],
"gevent": true,
"jinja": true,
"justMyCode": true,
"cwd": "${workspaceFolder}/api",
"python": "${workspaceFolder}/api/.venv/bin/python"
},
{
"name": "Python: Celery Worker (Solo)",
"type": "debugpy",
"request": "launch",
"module": "celery",
"env": {},
"args": [
"-A",
"app.celery",
"worker",
"-P",
"solo",
"-c",
"1",
"-Q",
"dataset,dataset_summary,priority_dataset,priority_pipeline,pipeline,mail,ops_trace,app_deletion,plugin,workflow_storage,conversation,workflow,schedule_poller,schedule_executor,triggered_workflow_dispatcher,trigger_refresh_executor,retention,workflow_based_app_execution",
"--loglevel",
"INFO"
],
"justMyCode": false,
"cwd": "${workspaceFolder}/api",
"python": "${workspaceFolder}/api/.venv/bin/python"
}
]
}

Some files were not shown because too many files have changed in this diff Show More