Giter Club home page Giter Club logo

Comments (9)

GoooDte avatar GoooDte commented on June 2, 2024

您好,可以修改一下代码,在输出结果的时候不使用ascii码
在最后json.dump中加入ensure_ascii=False

from deepke.

zhousuyu1111 avatar zhousuyu1111 commented on June 2, 2024

谢谢!
再请问一下,我的结果标签结果中为什么没有提取到关系?

结果如下:
[{"sentence": "如何演好自己的角色,请读《演员自我修养》《喜剧之王》周星驰崛起于穷困潦倒之中的独门秘笈", "head": "周星驰", "tail": "喜剧之王", "relation": "None"}, {"sentence": "《稻香》是周杰伦演唱的一首歌曲,由周杰伦作词、作曲,黄雨勋编曲,收录在周杰伦2008年10月15日发行的专辑《魔杰座》中", "head": "魔杰座", "tail": "稻香", "relation": "None"}]

triple_file.csv如下:
head_type,tail_type,relation
人物,影视作品,导演
音乐专辑,歌曲,所属专辑
人物,影视作品,主演

source_data.json如下:
[
{
"sentence": "如何演好自己的角色,请读《演员自我修养》《喜剧之王》周星驰崛起于穷困潦倒之中的独门秘笈",
"head": "周星驰",
"tail": "喜剧之王",
"head_offset": "26",
"tail_offset": "21"
},
//……
]

from deepke.

GoooDte avatar GoooDte commented on June 2, 2024

没有提取到关系是因为您的triple_file.csv里面没有包含您的source_data中的实体,您可以使用我们提供的triple_file: https://drive.google.com/file/d/1YpaMpivodG39p53MM9sMpB41q4EoiQhH/view?usp=sharing

from deepke.

zxlzr avatar zxlzr commented on June 2, 2024

请问您的问题解决了吗?

from deepke.

zhousuyu1111 avatar zhousuyu1111 commented on June 2, 2024

请问您的问题解决了吗?

没有解决,依旧没有提取到关系

from deepke.

zhousuyu1111 avatar zhousuyu1111 commented on June 2, 2024

谢谢!已经解决了,使用了您提供的triple_file!
没有提取成功是因为triple_file不包含实体,并且我的source-data中头实体和尾实体反了。

请问一下,有没有办法构造自己的三元组标签数据集?需要将涉及到的每个实体、关系加入自制的triple_file吗? 满足训练条件的数据量是多大?

from deepke.

GoooDte avatar GoooDte commented on June 2, 2024

您好,我们这里不涉及训练,是一个简易版的远程监督标注,您可以在我们构造的triple_file里添加自己需要的三元组进行标注

from deepke.

zxlzr avatar zxlzr commented on June 2, 2024

请问您的问题是否已解决?

from deepke.

zhousuyu1111 avatar zhousuyu1111 commented on June 2, 2024

已经解决,谢谢!

from deepke.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.