Export formats
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 35/100
- Issue 类型
- 功能
- 描述清晰度
- 基本清楚
- 活跃度
- 停滞
- 技术栈
- sql, sqlite
调研方向
从 src/semsql/builder/build.Makefile 开始,重点查看第 51 行附近的 main target,并追踪 rdftab、relation-graph TSV、prefixes 和 sql_schema/semsql.sql 如何为 SQLite build 提供输入。定义 build 命令如何选择 DSV 或 SQLite 输出,然后验证 DSV 输出会跳过 SQLite 加载,同时保持现有的数据库 build 完整不变。
由索引模型根据 Issue 内容生成。
描述
As part of KBase's work with ontologies in semsql, it would be very handy to be able to export as DSV directly, rather than going via the sqlite database.
We could put together a file similar to build.Makefile to perform the conversions, but I am wary of changes being made in the semsql sqlite build process that we'd have to ensure that we kept up with. I was therefore wondering about adapting the current build command to export either DSV or sqlite, depending on what args it is given.
build.Makefile line 51 onwards:
# -- MAIN TARGET --
# A db is constructed from
# (1) triples loaded using rdftab
# (2) A relation-graph TSV
%.db: %.owl %-$(RGSUFFIX).tsv $(PREFIX_CSV_PATH)
rm -f [email protected] && \
cat $(THIS_DIR)/sql_schema/semsql.sql | sqlite3 [email protected] && \
echo .exit | sqlite3 -echo [email protected] -cmd ".mode csv" -cmd ".import $(PREFIX_CSV_PATH) prefix" && \
rdftab [email protected] < $< && \
sqlite3 [email protected] -cmd '.separator "\t"' ".import $*-$(RGSUFFIX).tsv entailed_edge" && \
gzip -f $*-$(RGSUFFIX).tsv && \
cat $(THIS_DIR)/indexes/*.sql | sqlite3 [email protected] && \
echo "ALTER TABLE statements ADD COLUMN graph TEXT;" | sqlite3 [email protected] && \
(test -d views && find views -maxdepth 1 -name '$(notdir $*)*.sql' -type f -print0 | xargs -0 -I{} sh -c 'sqlite3 [email protected]< "$$1"' sh {} || echo no views ) && \
mv [email protected] $@
.PRECIOUS: %.db
Alter this so that if the desired output is DSV, the rdftab command is run but the sqlite db loading is omitted. Relevant files, including prefixes, relation graph, and schema SQL could be moved to a directory together or something like that.
- 主要语言
- Python
- 星标
- 70
- 派生
- 7
- 平均合并
- 4 小时 18 分钟
- 30 天内合并 PR
- 1
环境准备
- 提供 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
INCATools/semantic-sql 的其他 Issue
-
难度 4/5 3-5 天 新手友好度 52/100
INCATools/semantic-sql#124 ·
-
Migrate direct raw-S3 bbop-sqlite consumers to the semanticsql CDN可能重新可做 @caufieldjh 于 91 天前认领,目前没有进行中的 PR。 未关闭help wanted
INCATools/semantic-sql#115 · 7 条评论 · 已指派 1 人 ·
-
[bot] Cut a semsql release including the semanticsql.berkeleybop.io default可能重新可做 @caufieldjh 于 91 天前认领,目前没有进行中的 PR。 未关闭enhancement
INCATools/semantic-sql#114 · 2 条评论 · 1 个 reaction · 已指派 1 人 ·
-
enhancement
难度 5/5 一周以上 新手友好度 35/100
INCATools/semantic-sql#111 · 1 条评论 ·
-
Integrate ENERO Foundry ontologies into Semantic-SQL可能已有人在做 @cmungall 于 197 天前认领。 未关闭enhancement
难度 4/5 3-5 天 新手友好度 48/100
INCATools/semantic-sql#107 ·
查看 INCATools/semantic-sql 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 72/100
-
难度 1/5 1 小时以内 新手友好度 62/100
-
难度 1/5 1 小时以内 新手友好度 70/100
-
bug
难度 2/5 1-3 小时 新手友好度 72/100
topoteretes/cognee#5773 ·
维护者通常 1 天内回复
-
MiKTeX: a failed build reports no errors because texify --quiet switches the log to file:line: style未关闭
难度 2/5 1-3 小时 新手友好度 74/100
SublimeText/LaTeXTools#1718 ·