Coder Social home page Coder Social logo

negex_modified's Introduction

##############################
# Author: Peter Kang	     #
# [email protected] #
#                            #
# Date: 05/14/2009	     #
##############################

negex.py -- A python module to implement Wendy Chapman's NegEx algorithm.

The original NegEx algorithm is published at:
http://www.dbmi.pitt.edu/chapman/NegEx.html

#####################
# Motivation:       #
#####################
The motivation to release this code is two-fold.

One goal is to make Wendy Chapman's NegEx
algorithm more accessible for server side (that is non-GUI) programming for
Python development for research purposes. The code was tested for research only
and no enterprise purposes of any kind.

The second goal is to try Ted Pedersen's suggestion for code sharing
as he describes in the 2008 Computational Lingusitics article.
Pedersen, T. "Empiricism is not a matter of faith." Computational Linguistics. 34: 465-470, 2008.
http://www.d.umn.edu/~tpederse/Pubs/pedersen-last-word-2008.pdf


######################
# Files:             #
######################
This package includes 5 files.
1) 	negex.py: Source code for the Python implementation of NegEx.
	It can tag definitive negations only or both definitive and possible negations.
	You will need to post process the output of GenNegEx. In a real task
	you might want to use simple regex rules to find the [NEGATED] and [POSSIBLE]
	tags and for example delete those phrases that are tagged before running a 
	concept extraction program.
2) 	wrapper.py: Source code for a short program to demonstrate using negex.py. Simply run this in Python.
3) 	negex_triggers.txt:
	This file lists the rules that were used with wrapper.py to test negex.py.
	Users are free to use anything as a rule but they should follow the style
	of the example rule file.
	Generate your rule file as needed.
4) 	Annotations-1-120-random.txt: The test kit. Format of the test kit and files
	with sentences to check negations for follows this structure:
	Number TAB Phrase TAB Sentence TAB Dummystring
	The output will have the following structure:
	Number TAB Phrase TAB Sentence TAB Dummystring TAB Sentence.with.tags TAB Decision TAB Scope.if.negated
5)	README: This file.


Copyright 2009 Peter Kang

you may not use this file except in compliance with the License. You may obtain a copy of the License at 

http://www.python.org/download/releases/2.5.4/license/

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 
WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and 
limitations under the License. 


######################
# Notes:             #
######################
// NOTES:
// Negation trigger terms are in the file: negex_triggers.txt.
//
// The code was written in Python 2.5.
//
// Tags are:    [PREN] - Prenegation rule tag
//              [POST] - Postnegation rule tag
//              [PREP] - Pre possible negation tag
//              [POSP] - Post possible negation tag
//              [PSEU] - Pseudo negation tag
//              [CONJ] - Conjunction tag
//              [PHRASE] - Term is recognized from the term list, we search negation for but was NOT negated
//              [NEGATED] - Term was recognized from term list, and it was found being negated
//              [POSSIBLE] - Term was recognized from term list, and was found as possible negation
//								
//

negex_modified's People

Contributors

97harsh avatar

Watchers

 avatar  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.