Giter Club home page Giter Club logo

ieglm's Introduction

IEGLM

该项目是使用ChatGLM-6B模型在信息抽取(IE)任务上进行高效微调的项目,起名为IEGLM。微调方式参考ptuning/README.md

基础版本

模式输入输出形式定义为:

input: 你现在是一个信息抽取模型。已知候选的关系列表:[relation1, relation2, ...];句子:sentence;请从句子中抽取出可能存在的头实体(Subject)与尾实体(Object),并给出对应的关系三元组。请按照(Subject,Relation,Object)的格式回答。

output: (subject1, relation1, object1),(subject2, relation2, object2),...

具体构造方式参考ptuning/RelationExtraction/process_data.py

思维链

除此之外,为了提升模型的推理能力,本项目还尝试利用思维链(Chain-of-thoughts, COT)的方法对输入输出进行改进。于是输入和输出形式定义为:

input: 给定句子:sentence
       你现在是一个信息抽取模型。请根据候选的关系列表:[relation1, relation2, ...],从以上句子中抽取出可能存在的头实体(Subject)与尾实体(Object),并给出对应的关系三元组。请先找出存在的关系,再将关系三元组按照(Subject,Relation,Object)的格式回答。

output: 句子中存在的关系为:[relation1, relation2]。因此句子中包含的关系三元组为:(subject1, relation1, object1),(subject2, relation2, object2),...

具体构造方式参考ptuning/RelationExtraction/process_data_cot.py

ieglm's People

Contributors

qiao0313 avatar

Stargazers

 avatar

Watchers

 avatar

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.