0% found this document useful (0 votes)
75 views33 pages

AI in Agricultural Communication

The document discusses the integration of Artificial Intelligence (AI) into agricultural communication, highlighting its role in enhancing information exchange among farmers and stakeholders to promote sustainable practices. It outlines various AI tools, such as chatbots and machine learning, that provide real-time advice and support to address agricultural challenges. The study aims to explore how these technologies can improve decision-making and accessibility in rural areas, ultimately contributing to more resilient agricultural systems.

Uploaded by

cssanjaycs438
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
75 views33 pages

AI in Agricultural Communication

The document discusses the integration of Artificial Intelligence (AI) into agricultural communication, highlighting its role in enhancing information exchange among farmers and stakeholders to promote sustainable practices. It outlines various AI tools, such as chatbots and machine learning, that provide real-time advice and support to address agricultural challenges. The study aims to explore how these technologies can improve decision-making and accessibility in rural areas, ultimately contributing to more resilient agricultural systems.

Uploaded by

cssanjaycs438
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Agricultural Communication and AI Assistance 2024-25

CHAPTER 1
INTRODUCTION
1.1 Introduction
Agricultural communication is the process of sharing information, technologies, and
innovations among farmers, researchers, extension workers, agribusinesses, and
policymakers to support informed decision-making and sustainable agricultural
development. In the face of growing global challenges such as climate change, food
insecurity, and limited resources, the need for timely and effective communication in
agriculture has become more critical than ever. The integration of Artificial Intelligence
(AI) into this field has brought transformative changes, enabling faster, more accurate, and
personalized communication. AI tools such as chatbots, machine learning, image
recognition, and natural language processing are being used to deliver real-time farming
advice, diagnose plant diseases, forecast weather and yields, and translate complex data into
simple, local-language formats. These innovations not only enhance access to reliable
agricultural information, especially in rural and underserved areas, but also improve the
overall efficiency of extension services. The collaboration between agricultural
communication and AI assistance is paving the way for smarter, more resilient, and
inclusive agricultural systems that can adapt to the evolving needs of farmers and global
food production.
1.2 Aim
The aim of this study is to explore the integration of Artificial Intelligence (AI) into
agricultural communication, with a focus on how AI technologies enhance the effectiveness,
accessibility, and accuracy of information exchange among farmers, researchers, extension
agents, and other stakeholders. This research seeks to examine the potential of AI-assisted
communication tools in addressing agricultural challenges, improving decision-making, and
promoting sustainable farming practices, especially in rural and resource-limited settings.
1.3 Scope
The integration of agricultural communication and AI offers personalized, data-driven
support to farmers by enabling real-time, multilingual advice through tools like chatbots
and voice assistants. These technologies simplify complex research, forecast market trends,
and provide timely alerts for issues like pest outbreaks or extreme weather. AI also enhances
education and awareness through targeted outreach and helps combat misinformation.

Dept. of Computer Science, St. Philomena’s College,Mysore. 1


Agricultural Communication and AI Assistance 2024-25

1.4 Objective
To explore and analyze how artificial intelligence can enhance agricultural communication
by improving the efficiency, accessibility, and personalization of information delivery to
farmers and stakeholders, with the aim of supporting informed decision-making, promoting
sustainable practices, and bridging the gap between agricultural research, policy, and rural
communities.

Dept. of Computer Science, ,St. Philomena’s College,Mysore. 2


Agricultural Communication and AI Assistance 2024-25

CHAPTER 2
LITERATURE SURVEY
2.1 Review of literature survey
Miss D. Hemasai and her team have undertaken a project entitled “Agriculture Helper
Chatbot for Smart Agriculture Using Artificial Intelligence” (2023), which underscores the
significance of agriculture in contributing to India’s GDP and employment. This initiative
features a mobile application designed to support farmers through a multilingual voice bot
and a suggestion bot. The voice bot leverages Google Translator, pyttsx3, and Google
search engines to address inquiries in various languages, while the suggestion bot provides
recommendations regarding weather conditions, crop selection, fertilizers, and soil
management. Additionally, the application incorporates a portal that enables farmers to
register and market their produce across the country. It employs convolutional neural
networks (CNN) to handle data complexity and delivers localized agricultural insights.
Future developments are planned to include the identification of crop diseases and
recommendations for optimal planting and harvesting periods.
Ms. M. Anitha and her team have created an innovative virtual assistant in their project
titled "Agriculture Helper Chatbot Using Deep Learning," aimed at assisting farmers with
a range of agricultural tasks. This chatbot utilizes sophisticated deep learning
methodologies, such as natural language processing (NLP) and computer vision, to deliver
precise and tailored information to farmers. It aids in making informed decisions regarding
crop selection, disease identification, soil management, and other critical agricultural
factors. By interpreting natural language inquiries and evaluating images of crops or pests,
the chatbot provides pertinent recommendations and solutions. It features a user-friendly
interface that allows for interaction through text input or image uploads, ensuring wide
accessibility. The system is designed to enhance agricultural practices, boost productivity,
and promote sustainable farming techniques by supplying timely and accurate information.
In their 2023 initiative titled "AGRICULTURE HELPER CHATBOT AI," A. Anjali and S.
Rajender present the mobile application "TalkBot," designed to tackle the challenges
encountered by farmers in India. The agricultural sector plays a vital role in the nation's
economy; however, numerous smallholders and farmers in remote regions often lack access
to crucial agricultural knowledge and technologies. Traditional approaches, such as
government field visits, fall short in addressing their varied requirements.

Dept. of Computer Science, St. Philomena’s College,Mysore. 3


Agricultural Communication and AI Assistance 2024-25

The "TalkBot" mobile application incorporates a chatbot interface driven by artificial


intelligence, allowing farmers to obtain quick and user-friendly answers to inquiries related
to crop diseases, fertilization methods, and best farming practices. By promoting direct
engagement with advanced technology, the chatbot aspires to improve farming efficiency
and productivity, thus contributing to sustainable agricultural development in India. Future
enhancements for the app include features for crop disease identification and personalized
crop recommendations based on market trends, climate conditions, and soil characteristics.
These improvements aim to equip farmers with timely and customized information,
ultimately leading to better agricultural outcomes nationwide.
In their 2022 initiative titled "KISAN MITRA: AN INTELLIGENT CHATBOT," Y.
Alimkar and his team tackle the difficulties encountered by farmers within India's
agricultural sector. Although agriculture plays a crucial role in the nation's GDP and
employment, numerous farmers face challenges such as low income and insufficient
information regarding government programs, fertilizers, and farming practices. The
research presents a chatbot solution that employs natural language processing (NLP) to
deliver accessible and precise agricultural information. This intelligent chatbot is designed
to close the knowledge gap by providing real-time responses and guidance on crop
management and government initiatives. It operates as a virtual assistant, capable of
engaging with users in their local languages, thus ensuring its usability across various
agricultural communities. Future developments may involve the incorporation of sentiment
analysis and language translation features to further improve user engagement and
satisfaction. Ultimately, this project seeks to empower farmers with timely information and
support, contributing to increased agricultural productivity and economic development in
India.
2.2 Existing System
AI chatbots are transforming the agricultural sector by serving as advanced assistants for
farmers. These chatbots utilize natural language processing (NLP) to comprehend inquiries
from farmers in their native dialects, accommodating regional differences. Some chatbots,
such as KissanGPT, are powered by machine learning algorithms that enable them to
analyze extensive datasets related to agriculture. This analysis yields real-time insights
regarding crop selection, optimal planting times, pest management, and market trends,
thereby equipping farmers to make informed, data-driven decisions that can enhance both
yields and profitability.

Dept. of Computer Science, St. Philomena’s College,Mysore. 4


Agricultural Communication and AI Assistance 2024-25

Nevertheless, there remains significant potential for further development. Future versions
of these chatbots could eliminate language barriers by offering multilingual support, thus
broadening accessibility for a diverse array of farmers. Moreover, integrating offline
capabilities would ensure consistent service in regions with unreliable internet access.
Lastly, customizing recommendations based on specific crops and regional data through
targeted algorithms would deliver hyperlocalized guidance tailored to the distinct needs of
farmers. By focusing on these enhancements, AI chatbots could emerge as a formidable
catalyst for global advancements in agriculture.
The "Chatbot for Farmers Empowerment Assisted by AI" employs cutting-edge TFIDF
algorithms in conjunction with sophisticated NLP techniques. By leveraging TFIDF, the
system adeptly processes and analyzes user inquiries, ensuring the precise retrieval of
pertinent agricultural information. This methodology enhances the chatbot's capacity to
understand farmer questions related to crop management, weather predictions, market
dynamics, and government initiatives. The project's objective is to empower farmers by
providing effortless access to essential agricultural insights, thereby enhancing farming
practices and results. Through the innovative application of TFIDF, the chatbot marks a
significant advancement in promoting efficient and effective communication between
farmers and agricultural knowledge, thereby contributing to the progress of agricultural
practices and the empowerment of farming communities.
2.3 Proposed System
A proposed farmer’s assistance system with a chatbot would involve an AI-powered virtual
assistant that farmers can interact with to receive recommendations and guidance on
managing their crops, fertilizers, medicinal and nutritional values, irrigation, and also
deficiency in plants. Here are some of the key features and benefits of a proposed farmer
assistance system with a chatbot.
2.3.1 Natural Language Processing:
The chatbot would use natural language processing to understand and respond to farmers'
questions and requests, making it easy for farmers to interact with the system.
2.3.2 Data Analysis and Recommendations:
The chatbot would analyze data from multiple sources, such as weather sensors, satellite
imagery, soil sensors, and market data, to provide real-time recommendations and guidance
to farmers. For example, the chatbot could recommend the optimal time to plant or harvest
crops based on weather and soil conditions.

Dept. of Computer Science, St. Philomena’s College,Mysore. 5


Agricultural Communication and AI Assistance 2024-25

2.3.3 Continous Learning:


The chatbot would continuously learn from its interactions with farmers, improving its
recommendations and guidance over time. The more data the chatbot collects, the better it
can predict outcomes and provide accurate advice.
2.3.4 Automation:
The chatbot would automate many of the tasks that are currently done manually or semi-
automatically, such as scheduling irrigation, monitoring equipment health, and analysing
market data. This would save farmers time and reduce the risk of errors.
2.3.5 Accessbility:
The chatbot could be accessed from any device with an internet connection, making it easy for
farmers to interact with the system from anywhere, at any time.
2.3.6 Cost Effectiveness:
A chatbot-based system would be cost-effective for farmers, as it would not require
expensive hardware or software. The chatbot could be integrated into existing mobile
devices or computers, reducing the need for additional investments.
2.4 Advantages
Implementing a messaging application for agricultural communication with an AI chatbot
offers numerous advantages that can significantly enhance the farming experience. Firstly,
it provides farmers with instant access to expert advice and information, enabling them to
make informed decisions about crop management, pest control, and resource allocation.
Additionally, it can analyze data and provide personalized recommendations based on local
conditions, helping farmers optimize yields and reduce costs. By facilitating real-time
communication, the application fosters collaboration among farmers, agricultural experts,
and suppliers, ultimately leading to improved productivity and sustainability in the
agricultural sector. Furthermore, the integration of AI allows for continuous learning and
adaptation, ensuring that the information provided remains relevant and up-to-date with the
latest agricultural practices and technologies.

2.5 Overview of python


Python is an interpreted, general-purpose programming language. Guido van Rossum
created python, which was first made accessible in [Link] design philosophy makes
excellent use of significant whitespace and lays a heavy emphasis on code readability. Its
object-oriented methodology and language elements are made to help programmers write
clear, understandable code for both small and large projects. Python has dynamic typing

Dept. of Computer Science, St. Philomena’s College,Mysore. 6


Agricultural Communication and AI Assistance 2024-25

and garbage collection. The procedural, object-oriented, and functional programming


paradigms are all supported. Python is commonly referred to as a “batteries included”
language because of its vast standard library. In the late 1980s, Python envisioned as an
alternative to ABC. In Python 2.0, which was published in 2000, reference cycles and list
comprehensions were added to the garbage collection substantial language change that wasn’t
totally backward-compatible. Open source reference implementation known as C python was
created and is maintained by a global team of programmers. The resource used create Python and
C Python are supervised and managed by a nonprofit organization called the Python Software
Foundation.

2.6 Wordpress
WordPress is a widely used open-source content management system (CMS) that enables
users to create, manage, and publish websites easily without requiring advanced technical
skills. Launched in 2003, it has grown to become the most popular CMS globally,
powering over 40% of all websites on the internet. WordPress is built on PHP and uses a
MySQL or MariaDB database to store content, making it highly flexible and scalable for
various types of websites, from simple blogs to complex e-commerce platforms. One of
its key strengths is its extensive ecosystem of themes and plugins, which allow users to
customize the appearance and functionality of their sites without coding. Themes control
the visual design, while plugins add features such as SEO tools, contact forms, social
media integration, and security enhancements. The platform supports a user-friendly
interface with a block-based editor called Gutenberg, which simplifies content creation
through drag-and-drop blocks. WordPress also offers strong community support, with
thousands of developers and users contributing to its continuous improvement and
security. It supports multilingual websites, mobile responsiveness, and accessibility
standards, making it suitable for a global audience. Additionally, WordPress can be hosted
on various servers or used as a hosted service via [Link], catering to different
user preferences. Its open-source nature encourages transparency and innovation, allowing
developers to build custom solutions and integrations. Security is a priority, with regular
updates and a wide range of security plugins available. Overall, WordPress provides a
powerful, flexible, and user-friendly platform for individuals, businesses, and
organizations to establish a strong online presence efficiently and cost-effectively. In
conclusion, WordPress stands out as a versatile and user-friendly content management
system that empowers individuals and organizations to build and manage websites with
ease.

Dept. of Computer Science, St. Philomena’s College,Mysore. 7


Agricultural Communication and AI Assistance 2024-25

2.7 Google SEO


To optimize WordPress websites for Google SEO in 2025, focus on using SEO-friendly
themes and reliable SEO plugins to enhance site structure and metadata. Prioritize high-
quality, user-focused content and ensure your site is well-organized with descriptive URLs
and minimal duplicate content. Implement technical SEO by verifying your site is indexed,
choosing between WWW or non-WWW versions, and optimizing site speed and mobile
responsiveness. Use tools like Google Analytics and Search Console to monitor
performance and adapt to algorithm updates. Additionally, leverage AI-driven
optimization techniques, plan a clear website hierarchy, and maintain strong security
practices to improve rankings and user experience.

Dept. of Computer Science, St. Philomena’s College,Mysore. 8


Agricultural Communication and AI Assistance 2024-25

CHAPTER 3
SYSTEM REQUIREMENT SPECIFICATION
The System Requirement Analysis for the messaging application designed for agricultural
communication with an AI chatbot encompasses both hardware and software
specifications necessary for optimal performance. On the hardware side, the system should
support a cloud-based infrastructure capable of handling a minimum of 1,000 concurrent
users, ensuring scalability and reliability. This includes robust servers with sufficient CPU
and RAM to process real-time interactions and data analytics efficiently. The software
requirements involve a multi-tier architecture, with a frontend developed using
frameworks like [Link] or Flutter for mobile compatibility, and a backend built on
[Link] or Python (Flask/Django) to manage user requests and chatbot functionalities. The
application will utilize a relational or NoSQL database, such as MongoDB or PostgreSQL,
to store user data, chat history, and agricultural resources securely. Additionally,
integration with an AI model, such as OpenAI's API, will be essential for natural language
processing and generating accurate responses. Security measures, including data
encryption and compliance with data protection regulations, are critical to safeguarding
user information. Overall, the system must be designed for high availability, performance,
and user-friendliness, ensuring that farmers and agricultural stakeholders can access
timely and relevant information seamlessly.
3.1 Functional Requirements
Purpose: To define the requirements for a messaging application that facilitates
agricultural communication through an AI chatbot, aimed at improving farmers' access to
information and expert advice.
Scope: The application will serve farmers, agricultural experts, and suppliers, providing a
platform for real-time communication and information exchange
User Registration and Authentication:
• Users must be able to register and log in securely.
• Support for multi-factor authentication.
Chatbot Interaction:
• Users can interact with the AI chatbot via text and voice messages.
• The chatbot should provide responses to queries related to crop management, pest
control, weather updates, and best practices.

Dept. of Computer Science, St. Philomena’s College,Mysore. 9


Agricultural Communication and AI Assistance 2024-25

User Feedback Mechanism:


• Users can provide feedback on chatbot responses to improve accuracy and relevance
Notification System:
• Users receive notifications for important updates, such as weather alerts or new
resources.
3.2 Non-functional Requirements
• Performance
Since our project has used light weight technologies like HTML and bootstrap the
application should not use much resource for its execution.
• Reliability
The application is reliable as the data that has been captured from the user, details is stored
safe into the application and it is maintained confidentially.
• Availability
The availability of the application is very high as our application has 24*7 availability.
• Maintenance
our application is very easy to maintain as the resources are already published into the
cloud.
• Security
The application has high level security due to the restriction of unauthorized access.
• Integrity
The application doesn't save any cached data or consume system resources in the
background.
• Usability
The user interface ought to be clear, uncomplicated, and intuitive.

Dept. of Computer Science, St. Philomena’s College,Mysore. 10


Agricultural Communication and AI Assistance 2024-25

3.3 HARDWARE AND SOFTWARE REQUIREMENTS


3.3.1 Minimum-Hardware Requirements
• Central-Processor : Intel i5 2.4GHz
• Hard-Disk : 4OGB
• Ram : 2GB or above
3.3.2 Minimum-Software Requirements
• Operating System : Windows 7 and above
• Coding Language : Python
• Version : IDE 3.7 and above

Dept. of Computer Science, St. Philomena’s College,Mysore. 11


Agricultural Communication and AI Assistance 2024-25

CHAPTER 4
SYSTEM ANALYSIS
4.1 Detailed description of project
The Agricultural Communication Messaging Application is designed to facilitate seamless
communication between farmers, agricultural experts, and suppliers through an AI-
powered chatbot. The primary goal of this project is to empower farmers with instant
access to information, expert advice, and resources that can enhance their agricultural
practices, improve crop yields, and promote sustainable farming methods. By leveraging
modern technology, this application aims to bridge the information gap in the agricultural
sector, particularly in rural areas where access to expert knowledge may be limited.
The successful implementation of this project will lead to improved access to agricultural
information for farmers, enhanced communication with experts, and a more efficient
agricultural ecosystem. By leveraging AI technology, the application will provide timely
and relevant advice, ultimately contributing to increased productivity, sustainability, and
economic growth in the agricultural sector.
4.2 Feasibility study
The project-related problems are resolved with the help of the feasibility study. The
offered solution shows what a new system would look like.
4.2.1 System Feasibility
A feasibility analysis performed to select system that meets the performance requirements
at least cost. During product engineering we concentrate on three main areas of interest
Three essential are included in feasibility analysis.
• Economic Feasibi1ity.
• Operational Feasibility.
• Technical Feasibi1ity.
4.2.2 Economical Feasibility
The project's overall cost is quite reasonable due to the use of open source software. This
project is very economical because it doesn't need any supplementary equipment. The
discovery also allowed the company to manage expenses prior to a project receiving
official approval. This made it possible for the business to manage its resources well such
that the most lucrative project was chosen. Due to the Scalability application's annual
development and maintenance expenditures is economically feasible.
4.2.3 Operational Feasibility

Dept. of Computer Science, St. Philomena’s College,Mysore. 12


Agricultural Communication and AI Assistance 2024-25

Because any changes made to the indication will be accessible across the [Link]
application and software, for example, the project is operationally viable.
Since the application provides straightforward data segmentation routing to the servers,
operational scalability is achievable.
4.2.4 Technical Feasibility
Applications used by users to implement data transfer in hybrid networks There must be
no participation limitations or invalid reservations during the data transfer between the
source and the destination. to prevent bandwidth restrictions and channel fluctuations so
that data can be delivered rapidly to the intended location.
In terms of technology, the Scalability program supports widely used Python and CNN
Algorithm for data Comparison.

Dept. of Computer Science, St. Philomena’s College,Mysore. 12


Agricultural Communication and AI Assistance 2024-25

CHAPTER 5
SYSTEM DESIGN
5.1 System Architecture

Figure:5.1 System Architecture


The system architecture for the Agricultural Communication Messaging Application is
designed to ensure scalability, reliability, and efficient communication between users
(farmers, agricultural experts, and suppliers) and the AI chatbot. The architecture follows
a multi-tier approach, consisting of the following components:
[Link] interface:
• Chat Interface: For real-time interaction with the AI chatbot.
• Resource Library: A searchable database of articles, videos, and best practices.
• User Profile Management: For registration, authentication, and user settings.
• Feedback Mechanism: For users to provide feedback on chatbot responses.
[Link] Side:
• Application Server: Built using [Link] or Python (Flask/Django) to handle business
logic, user requests, and communication with the database and AI model.
• Authentication Service: Manages user registration, login, and session management,
implementing security measures such as JWT (JSON Web Tokens) for secure access.

Dept. of Computer Science, St. Philomena’s College,Mysore. 14


Agricultural Communication and AI Assistance 2024-25

[Link] Chatbot
• Natural Language Processing (NLP) Engine: Utilizes an AI model (e.g., OpenAI's
GPT) to process user queries and generate contextually relevant responses.
• Training Data: The chatbot is trained on agricultural datasets to ensure it provides
accurate and relevant information.
[Link] Layer
• Database Management System: A NoSQL database (e.g., MongoDB) or a relational
database (e.g., PostgreSQL) to store:
• User data (profiles, preferences)
• Chat history (user interactions with the chatbot)
• Feedback data (user ratings and comments on chatbot responses)
[Link] Infrastructure
• Hosting: The application is hosted on a cloud platform (e.g., AWS, Google Cloud, or
Azure) to ensure scalability and high availability.
• Load Balancer: Distributes incoming traffic across multiple servers to ensure
optimal performance and reliability.
[Link]
• Analytics Dashboard: For agricultural experts to analyze user interactions, trends,
and common queries, helping to tailor support and resources.
7. Notification
• Email/SMS Notifications: Optional features for users who prefer receiving
updates through email or SMS.
5.2 Data Flow Diagram
The skills and methods that enclose, operate, maintain, and disseminate information
between components of a machine as well as between a device and its surroundings are
graphically represented by Dataflow Diagram. Its Seen illustration elevates it to the status
of a powerful fashion statement among Users and Systems. The DFD structure enables
starting with a comprehensive review and increasing a structure of distinct diagrams. Why
DFD has been used extensively is explained by the reasons listed below:
• Determination of physical framework .
• development requirements Logical data stream of the framework.
• Simpleness of the documentation.
• Development of manual and electronic framework requirements.

Dept. of Computer Science, St. Philomena’s College,Mysore. 15


Agricultural Communication and AI Assistance 2024-25

5.2.1 Basic Notation:

Figure: 5.2.1 Basic notation


5.2.2 Data/Information Flow Diagram

Figure: 5.2.2 Level 0 dfd

Dept. of Computer Science, St. Philomena’s College,Mysore. 16


Agricultural Communication and AI Assistance 2024-25

5.2.3 User DFD

Figure: 5.2.3 user dfd


Above DFD diagram represents Agriculture Communication functionalities like Pre-
Processing,Feature Extraction, train with Dataset.

Dept. of Computer Science, St. Philomena’s College,Mysore. 17


Agricultural Communication and AI Assistance 2024-25

5.3 Use-Case Diagram


The use Case diagram provides a visual depiction of characters, the way use Cases are
organized inside a framework, and the interaction between a use Case and a performing
artist. The relationshipbetween the framework and external entities is depicted in the use
Case diagram. Every use case explains the benefits the framework provides its users.
During the exam procedure, the use of cases is frequently employed to separate and
distinguish the framework. This framework is Customized for each person and their
unique tasks. In this case , the character stands in for the various ways that users engage
with the system. In this situation Users may be anything from processors to people to
software to other hardware parts.
The proposed system contains two main actors. and administrator, respectively. The use
case diagram below illustrates the capabilities of each actor with the ability to act. Using
a username and password to log in securely is one of the administrator's use cases. The
actor's access is shown in the use case diagram,And run-time authentication is used to
show the actor's properties.

Figure:5.3 Use-Case for user


The user role is to
• Live Video
• Processing
• Normalization
• Feature Extraction

Dept. of Computer Science, St. Philomena’s College,Mysore. 18


Agricultural Communication and AI Assistance 2024-25

• CNN Model
• Train with dataset

5.4 Sequence Diagram


Sequence diagrams depict the interactions between the modules in an application. They
are also arranged as examples in the figure. Sequence diagrams may also be referred to as
event scenarios oreven graphs. A sequence diagram shows how data and commands are
exchanged. The UML (Unified Modelling language) framework views grouping graphs
as being very advantageous sincethey offer an active view point.

Figure: 5.4 Sequence

5.5 Activity Diagram


In this developed project the Activity diagrams illustrate the overall flow of control. This
diagram symbolizes the goings-on taking place all through the process. There are
numerous incidents that are user-related. It starts with a person registering by giving
accurate information, including a username and password, and logging in with those
specifics. Next the user can register and uploaddata and application process the data using
KNN and SVM algorithm and predict the result.
Basic Notations:

Dept. of Computer Science, St. Philomena’s College,Mysore. 19


Agricultural Communication and AI Assistance 2024-25

Initial activity:

Final Activity:

The activity diagram ends with a bull's eye indication, often known as a final activity.

Activity:
The depiction is a rectangle with rounded (almost oval) edges.

Decisions
A diamond stands for the justification for needing to make a choice.

Workflow
The workflow is represented by an arrow. The activity diagram shows the workflow's
direction.

Figure: 5.5 Activity diagram

Dept. of Computer Science, St. Philomena’s College,Mysore. 20


Agricultural Communication and AI Assistance 2024-25

An activity diagram is a visual representation of the workflow of a system, illustrating the


sequence of activities and decisions involved in a process. For a Chatbot Module in a
WordPress application, the activity diagram can depict the interactions between the user
and the chatbot, as well as the backend processes involved. The activity diagram for the
Chatbot Module provides a clear overview of the user interaction process, highlighting the
flow of activities and decision points. This visual representation can help developers and
stakeholders understand how the chatbot operates, ensuring that all necessary
functionalities are implemented effectively. By following this diagram, you can create a
user-friendly and efficient chatbot experience on your WordPress site..

Dept. of Computer Science, St. Philomena’s College,Mysore. 21


Agricultural Communication and AI Assistance 2024-25

CHAPTER 6
SYSTEM-IMPLEMENTATION
6.1 Module Wise Implementation Details
6.1.1 Messaging Module:
Implementing a Messaging Module in a WordPress application can enhance user
interaction and engagement. This module can facilitate real-time communication between
users, support inquiries, or notifications. Below is a detailed plan for developing a
Messaging Module, including objectives, features, and implementation steps. The
Messaging Module is a valuable addition to a WordPress site, fostering communication
and engagement among users. By following this implementation plan, you can create a
robust messaging system that meets user needs and enhances the overall user experience.
Whether you choose to use an existing plugin or develop a custom solution, ensure that the
module is secure, user-friendly, and well-integrated with the rest of your WordPress site.
6.1.2 Chatbot Module:
Implementing a Chatbot Module in a WordPress application can significantly enhance
user interaction, provide instant support, and improve overall user experience. Below is
a detailed plan for developing a Chatbot Module, including objectives, features, and
implementation steps. In conclusion, implementing a Chatbot Module in a WordPress site
can greatly enhance user engagement and streamline customer support. By providing
instant responses to user inquiries, guiding visitors through the site, and offering
personalized interactions, a chatbot can significantly improve the overall user experience.
Whether you choose to utilize an existing chatbot plugin or develop a custom solution, it
is essential to focus on creating a seamless and intuitive conversation flow that addresses
user needs effectively.

Dept. of Computer Science, St. Philomena’s College,Mysore. 22


Agricultural Communication and AI Assistance 2024-25

6.2 Snap Shots

Figure: 6.2.1 Farmer Chat Home

Figure: 6.2.2 Login Page

Dept. of Computer Science, St. Philomena’s College,Mysore. 23


Agricultural Communication and AI Assistance 2024-25

Figure: 6.2.3 Ask Your Question

Figure: 6.2.4 Real-time Solution

Dept. of Computer Science, St. Philomena’s College,Mysore. 24


Agricultural Communication and AI Assistance 2024-25

Figure: 6.2.5 Chat History

Figure: 6.2.6 Feedback&Ratings

Dept. of Computer Science, St. Philomena’s College,Mysore. 25


Agricultural Communication and AI Assistance 2024-25

6.3 Source Code


import os
import time
import streamlit as st
from [Link] import ConversationBufferMemory
from [Link] import initialize_agent, AgentType
from langchain.chat_models import ChatOpenAI
from [Link] import SystemMessage, HumanMessage, AIMessage
from langchain_community.tools import WikipediaQueryRun, ArxivQueryRun,
DuckDuckGoSearchRun
from langchain_community.utilities import WikipediaAPIWrapper, ArxivAPIWrapper,
DuckDuckGoSearchAPIWrapper
from langdetect import detect
from deep_translator import GoogleTranslator
from dotenv import load_dotenv, find_dotenv
load_dotenv(find_dotenv())
wiki=WikipediaQueryRun(api_wrapper=WikipediaAPIWrapper(top_k_results=1,
doc_content_chars_max=200))
arxiv=ArxivQueryRun(api_wrapper=ArxivAPIWrapper(top_k_results=1,
doc_content_chars_max=200))
duckduckgo_search=DuckDuckGoSearchRun(api_wrapper=DuckDuckGoSearchAPIWr
apper(region="in-en", time="y", max_results=2))
tools = [wiki, arxiv, duckduckgo_search]
def load_llm():
return ChatOpenAI(
model_name="llama3-70b-8192",
temperature=1,
openai_api_key=[Link]("GROQ_API_KEY"),
openai_api_base="[Link]
)

Dept. of Computer Science, St. Philomena’s College,Mysore. 26


Agricultural Communication and AI Assistance 2024-25

const express = require('express');


const { GoogleGenerativeAI, HarmCategory, HarmBlockThreshold } =
require('@google/generative-ai');
const dotenv = require('dotenv').config();

const app = express();


const port = [Link] || 3000;
[Link]([Link]());
const MODEL_NAME = "gemini-pro";
const API_KEY = [Link].API_KEY;

async function runChat(userInput) {


const genAI = new GoogleGenerativeAI(API_KEY);
const model = [Link]({ model: MODEL_NAME });

const generationConfig = {
temperature: 0.9,
topK: 1,
topP: 1,
maxOutputTokens: 1000,
};

const safetySettings = [
{
category: HarmCategory.HARM_CATEGORY_HARASSMENT,
threshold:
HarmBlockThreshold.BLOCK_MEDIUM_AND_ABOVE,
}

Dept. of Computer Science, St. Philomena’s College,Mysore. 27


Agricultural Communication and AI Assistance 2024-25

];
const chat = [Link]({
generationConfig,
safetySettings,
history: [
{
role: "user",
parts: [{ text: "You are an agriculture expert assistant named
AgriBot." }],
},
{
role: "model",
parts: [{ text: "Hello! I'm AgriBot, your agriculture assistant." }],
},
],
});

const result = await [Link](userInput);


return [Link]();
}

[Link]('/chat', async (req, res) => {


try {
const userInput = [Link]?.userInput;
if (!userInput) {
return [Link](400).json({ error: 'Invalid request body' });
}

Dept. of Computer Science, St. Philomena’s College,Mysore. 28


Agricultural Communication and AI Assistance 2024-25

CHAPTER 7
SYSTEM TESTING
7.1 Testing process
Software testing involves operating a software component, system component, or system
component in order to confirm one or more of the stated properties. It helps to emphasize
how well the system or software satisfies the user's stated needs, responds as indicated, and
needs to be deployed and used in all envisioned contexts. Based on client needs, we have
incorporated a range of test cases into our program. Theunit, integration, and system levels
of this application have all been tested. The following is a list of the casings tests that we
considered.

Figure: 7.1 Testing-Process

Dept. of Computer Science, St. Philomena’s College,Mysore. 29


Agricultural Communication and AI Assistance 2024-25

7.2 test cases


There are many test cases performed on the system, those test cases are as follows
7.2.1 Registration test cases
Test
case Testing Scenario Expected Result Result
number

01 Clicking submit without entering details Alert" Please fill all


details" pass

02 Clicking submit without entering Alert" Please fill


Username Username" pass

03 Clicking submit without entering Alert" Please fill


password password" pass

04 Clicking submit without entering e mail Alert "Please fill


id email id" pass

06 Clicking submit entering confirm Alert "password and


password data which is not matching confirm password do pass
with password data not match"

Table 7.2.1 registration test cases


7.2.2 Login test cases
Test
case Testing Scenario Expected Result Result
number
01 Clicking submit without entering Alert "Please enter the user Pass
name and password"
login details
02 Clicking submit without entering Alert "Please enter Pass
password"
password

Dept. of Computer Science, St. Philomena’s College,Mysore. 30


Agricultural Communication and AI Assistance 2024-25

03 Clicking submit without entering Pass


username Alert "Please enter the
username"
05 Clicking submit without entering Alert" Invalid user " pass
wrong password

06 Clicking submit without entering Alert" Invalid user " pass


wrong username and wrong
password

Table 7.2.2 Login test cases


7.2.3 video capturing test cases
Test case number Testing Scenario Expected Result Result
Clicking Capture Alert “Please
01 without allowing Enable Camera” pass
camera
Clicking Capture
02 with allowing Video recorded pass
camera
Clicking upload Alert “Please fail
03 without Capturing capture video”
video
Clicking upload pass
04 with Capturing Video uploaded
video
05 Uploading video Generate play list pass
based on Emotion
Table 7.2.3 video capturing test cases
The Code Testing is a courageous investigational program. A path is a particular
configuration ofconditions that the software controls. This approach to specification testing
examines what the program ought to be able to do and how it oughtto behave in various
situations.
Acceptance: When there are no issues with the measures' accuracy, the system has
successfully completed an acceptance test. When a system finally achieves all
requirements, it becomes operational and accepted.

Dept. of Computer Science, St. Philomena’s College,Mysore. 31


Agricultural Communication and AI Assistance 2024-25

7.3 System Testing


System testing is tests the total framework. Framework testing is done after the consummation
Unit testing as well as reconciliation testing. It will test the general conduct of the framework.
It will checks the exhibition and usefulness of the framework.
7.4 Unit Testing
Unit testing is a is a recognition of programming situating out wherein character
contraptions/added The components of a product are examined. The objective is to verify that
eachsection of the product application programming proceeds according to schedule. A
unit is the smallest tested element of any product program or utility program. It typically just
has one or two informational sources and, for the most part, one yield.
7.5 integration testing
Application programming in programming Character devices are combined and evaluated as a
hard and fast during programming testing, a certification process. This level of analysis is being
carried out to findissues with the exchange of associated devices. Test pilots and test nails are
tools that help in integrationtesting.

7.6 System Test Cases


The practice of assessing a product, program, or utility in light of how its design specifies that
it should behave is known as system testing. We shall create check circumstances that are
specificallyassembled in reference to the behavior of this current gadget without really seeing
this framework in action.

Dept. of Computer Science, St. Philomena’s College,Mysore. 32


Agricultural Communication and AI Assistance 2024-25

CHAPTER 8
CONCLUSION:
The Agricultural Communication Messaging Application, featuring an AI-powered chatbot,
stands as a transformative solution aimed at revolutionizing the way farmers access information
and interact with agricultural experts. By bridging the information gap in the agricultural sector,
particularly in rural areas, this application empowers farmers with instant access to vital
resources, expert advice, and real-time communication. The integration of multi-language
support ensures inclusivity, allowing diverse farming communities to engage effectively.
Through its user-friendly interface and robust backend architecture, the application not only
enhances the efficiency of agricultural practices but also fosters collaboration among farmers,
experts, and suppliers. The AI chatbot's ability to provide personalized recommendations based
on user queries and local conditions further enriches the user experience, making it a valuable
tool for decision-making in crop management and pest control.
8.1 Bibilography
• Choudhary, A., & Singh, R. (2020). Artificial Intelligence in Agriculture: A
Comprehensive Guide. Springer.
• Kaur, R., & Singh, S. (2019). Smart Agriculture: A Comprehensive Overview of
Technologies and Applications. Wiley.
• Ranjan, R., & Kumar, A. (2021). "The Role of AI in Agriculture: Opportunities and
Challenges." Journal of Agricultural Science and Technology, 23(4), 123-135
8.1 Reference
• Digital Green. (2023). "[Link]: A Messaging Application for Agricultural
Communication." Retrieved from [Link]
• Kamble, S. S., Gunasekaran, A., & Sharma, R. (2020). "A Framework for Smart
Agriculture: A Review." Computers and Electronics in Agriculture, 170, 105-120. DOI:
10.1016/[Link].2019.105120.

Dept. of Computer Science, St. Philomena’s College,Mysore. 33

You might also like