twlaw UI (abstract)
前情提要
在 g0v/twlaw project 中,我們已經將法律條文歷年的變更轉換成 git repository。但是為了讓社會大眾與法律界人士能有效利用,我們需要一個網站來呈現、讓大家討論對現類法條的想法、進而提出條文的修正。
Target Audiance
- 立法委員:將提案更透明地呈現,誘發公開的討論,一起提高修正的品質。
- 法律人:希望提供法界人士、學生一個平台,讓他們能發表對現行法條的修正。同時提供各種對修法有用的資訊,讓整個過程更有效率。最後希望能將好的修正送進立法院。
- 社會大眾:除了提供基本的查詢介面,也希望能讓大眾關注:
- 已被提出的修正中的條文
- 比較不同版本的修法
- 對尚未被提出的修法建議:
- 表達支持
- 表達支持(含本修法提出者之後更新的任何版本)
- 提出意見
- 動民主有預計要做類似的事情, 也許可以整合, 或以各自提供 Open API 給對方的方式來做
相關專案
- http://publicmarkup.org/ - 線上法律提案 review/comment
- 立法院提案 api sample: 提案資訊、修法內容
- 立法院提案 view: http://ly.g0v.tw/bill/1011130070300200
- 法律 api: 憲法第44條
UI features
- Browse
- Web entry point. May provide related resources as well.
- Search, should support abbreviation (e.g. 兒少法)
- Diff view
- Fork
Given the git backend, it should be fairly easy to implement advance features like, browsing the law in 1985, showing diff from 2000 to 2010, etc.
Possible workflow
This is what we really want.
- Fork -> review -> send PR
- Issue. What needs to be fixed, the priority, the progress. Who are working on it.
Tasks
Non-dev task
Frontend task
- May just use github API as backend
- Browse interface (render a github .md file)
- Search interface (use github search api? or with our own index)
- Diff view
- Fork view (existing fork, diff between fork, etc.)
Issue tracking (may just use github interface)
Backend task
- Caveat: since we check in law changes as git commit, what if we need to modify mistake in the commit history? How do we maintain the history view after the change? Currently it happens quite often because of the problematic source page. Can we just push -f to master, and expect all the fork to merge without mess up the history too much?
- Refine crawler
- Source page is not stable, and crawling involves human input
- Source-to-Markdown/JSON-to-git translation
- This was done in twlaw, but we need to fix git translation to support incremental changes.
- Open question: is putting every laws in a single git repo a good idea? Should we split them by law?
Memo
- https://code.google.com/p/google-diff-match-patch/