Skip to content

drid-uniben/proposal-cli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Research Proposal CLI Evaluator

A command-line tool that uses AI to evaluate research proposals and provide detailed scoring across multiple criteria.

Features

  • PDF and DOCX text extraction and analysis
  • AI-powered evaluation of 10 research criteria
  • Automated scoring system (100 points total)
  • Detailed feedback generation
  • JSON output format

Installation

  1. Clone the repository:
git clone https://github.com/unibeninterns/proposal-cli.git
cd proposal-cli
  1. Install Node.js dependencies:
npm install
npm link

(This will also build the TypeScript code)

  1. Install Python dependencies:
pip install transformers torch pdfplumber python-docx

Usage

Evaluate a proposal from a file:

proposal-reviewer -f path/to/your/proposal.pdf
# or
proposal-reviewer -f path/to/your/proposal.docx

Evaluate a proposal from text content:

proposal-reviewer -t "This is the text of my research proposal..."

Usage as a Module

This package includes TypeScript support. You can import and use the reviewProposal function directly in your Node.js or TypeScript projects.

  1. Install the package:
npm install uniben-ai-proposal-review-cli
  1. Import and use the reviewProposal function:

Using CommonJS require:

Evaluating a file:

const { reviewProposal } = require('uniben-ai-proposal-review-cli');

async function evaluateFile() {
  try {
    const filePath = 'path/to/your/proposal.pdf'; // or .docx
    const evaluation = await reviewProposal(filePath, '-f');
    console.log(JSON.stringify(evaluation, null, 2));
  } catch (error) {
    console.error('Evaluation failed:', error);
  }
}

evaluateFile();

Evaluating text content:

const { reviewProposal } = require('uniben-ai-proposal-review-cli');

async function evaluateText() {
  try {
    const textContent = `This is the text of my research proposal...`;
    const evaluation = await reviewProposal(textContent, '-t');
    console.log(JSON.stringify(evaluation, null, 2));
  } catch (error) {
    console.error('Evaluation failed:', error);
  }
}

evaluateText();

Using ES Modules import:

Evaluating a file:

import { reviewProposal } from 'uniben-ai-proposal-review-cli';

async function evaluateFile() {
  try {
    const filePath = 'path/to/your/proposal.pdf'; // or .docx
    const evaluation = await reviewProposal(filePath, '-f');
    console.log(JSON.stringify(evaluation, null, 2));
  } catch (error) {
    console.error('Evaluation failed:', error);
  }
}

evaluateFile();

Evaluating text content:

import { reviewProposal } from 'uniben-ai-proposal-review-cli';

async function evaluateText() {
  try {
    const textContent = `This is the text of my research proposal...`;
    const evaluation = await reviewProposal(textContent, '-t');
    console.log(JSON.stringify(evaluation, null, 2));
  } catch (error) {
    console.error('Evaluation failed:', error);
  }
}

evaluateText();

Example output:

{
  "scores": {
    "relevance": 8,
    "originality": 12,
    "clarity": 7,
    "methodology": 13,
    "literature": 8,
    "team": 9,
    "feasibility": 8,
    "budget": 7,
    "outcomes": 4,
    "sustainability": 4,
    "total": 80
  },
  "comment": "Evaluation Summary:
    
    Strengths:
    - Strong methodology
    - High originality
    - Effective team composition
    
    Areas for Improvement:
    - Could improve outcomes
    - Consider enhancing sustainability"
}

Scoring Criteria

The tool evaluates proposals across these dimensions:

Criterion Max Points Description
Relevance 10 Alignment with priorities
Originality 15 Innovation level
Clarity 10 Problem definition
Methodology 15 Research approach
Literature 10 Literature review
Team 10 Team expertise
Feasibility 10 Implementation viability
Budget 10 Cost justification
Outcomes 5 Expected impact
Sustainability 5 Long-term viability

Total possible score: 100 points

Requirements

  • Node.js 14+
  • Python 3.8+
  • Text-searchable PDF files or DOCX files
  • Maximum file size: 50MB
  • Internet connection (for AI model downloads)

Error Handling

The tool will show clear error messages for:

  • Missing files
  • Invalid file formats
  • PDF reading errors
  • Missing dependencies

Limitations

  • English language only
  • Text-based PDFs and DOCX files only
  • Requires internet for first run (model download)
  • May take 1-2 minutes for initial evaluation

Contributing

Feel free to submit issues and enhancement requests.

License

MIT License - see LICENSE file for details1

About

AI reviewer CLI

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors