Human-ground emotion association recognition method and device based on large language model

Through the human-place emotional association recognition method based on the large language model, entities and emotional elements related to place attachment are extracted, emotional vectors are calculated, and the human-place emotional network is constructed, which solves the problem of insufficient emotional connection between people and urban space in the existing technology. It achieves more accurate sentiment analysis and customized suggestions for urban renewal, and promotes urban renewal in a humanized direction.

CN118820847APending Publication Date: 2024-10-22SHANGHAI UNIV
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202410826641.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-25
Publication Date
2024-10-22

AI Technical Summary

Technical Problem

Existing technologies are deficient in exploring the emotional connections and interactions between people and the urban spatial environment, which affects the potential of urban renewal projects in improving residents’ emotional satisfaction.

Method used

The human-place emotional association identification method based on the large language model is used to obtain the text to be recognized, extract entities and emotional elements related to place attachment, calculate the emotional vectors of individuals and places, construct a human-place emotional network map, and deeply mine and Quantifying emotional connections between people and places in urban neighborhoods.

Benefits of technology

It achieves a more accurate identification and understanding of residents' emotional responses to urban space, provides a new perspective and method, provides customized suggestions for the planning and design of urban renewal projects, and promotes urban renewal in a humane and sustainable direction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118820847A_ABST
    Figure CN118820847A_ABST
Patent Text Reader

Abstract

The invention relates to a human-ground emotion association recognition method and device based on a large language model. The method comprises the following steps of obtaining a to-be-recognized text; using a first emotion association analysis model to extract entities and emotion elements related to local attachment from the to-be-recognized text; based on a human-earth coordinate system and the extracted entities and emotion elements, using a second emotion correlation analysis model to calculate emotion vectors of each individual and each place; based on the obtained emotion vectors, key features are extracted, and a person-place emotion network atlas is constructed and obtained; wherein the first emotion association analysis model and the second emotion association analysis model are both constructed based on a large language model. Compared with the prior art, the method has the advantages that human-ground emotion recognition is accurately realized, so that more humanized and more targeted improvement is realized in the urban planning and updating process, and the living quality and happiness of residents are effectively improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of urban planning and renewal, and in particular to a method and device for identifying human-land emotion associations based on a large language model. Background Art

[0002] Urban renewal is a complex process, involving multiple aspects, including urban planning, architectural design, socioeconomics, and culture. Traditional urban renewal often focuses on infrastructure construction and economic development, while neglecting residents' emotional needs for urban space and environment. How to better consider residents' emotional needs during urban renewal and improve the quality and humanization of urban space has become one of the most pressing issues in the field. With the development of artificial intelligence technology, especially large language models, we have more tools to understand and analyze the emotional connection between people and land. This allows us to better consider residents' emotional needs in urban renewal and improve their satisfaction and well-being.

[0003] A literature search of existing technologies reveals that research on sentiment analysis primarily focuses on text analysis and recognition, aiming to automatically detect, classify, and understand human emotions and attitudes. In the Chinese patent application "A Multimodal Question Answering Method and System Based on Emotion Recognition and a Large Language Model" (Patent No. ZL202410316081.X), Pan Xianzhen et al. propose a multimodal question answering system that combines emotion recognition and a large language model. This system provides both text and voice question answering services, improves user experience through emotion recognition, and meets market demand for intelligent question answering. In the Chinese patent application "Text Sentiment Classification Method, Device, Electronic Device, and Storage Medium" (Application No. 202211526406.4), Fan Peng proposes a text sentiment classification method that improves sentiment classification accuracy by creating adversarial samples, fusing feature vectors, constructing a prior distribution, generating samples that match the target sentiment label, and training a text sentiment classification model. While existing research has made progress in text sentiment analysis, it lacks significant insights into the emotional connections and interactions between people and urban spatial environments, hindering the potential of urban renewal projects to enhance residents' emotional satisfaction. Summary of the Invention

[0004] The purpose of the present invention is to overcome the defects of the above-mentioned prior art and provide a method and device for human-land emotion association recognition based on a large language model that accurately realizes emotion recognition and provides effective support for urban renewal.

[0005] The purpose of the present invention can be achieved by the following technical solutions:

[0006] A method for identifying human-ground emotion association based on a large language model, comprising the following steps:

[0007] Get the text to be recognized;

[0008] extracting entities and sentiment elements related to place attachment from the text to be identified using a first sentiment association analysis model;

[0009] Based on the person-place coordinate system and the extracted entities and emotional elements, the emotion vector of each individual and place is calculated using the second emotion association analysis model;

[0010] Based on the obtained emotion vector, key features are extracted to construct a human-land emotion network map;

[0011] The first sentiment association analysis model and the second sentiment association analysis model are both constructed based on a large language model.

[0012] Furthermore, the text to be recognized is based on social media data and interview records of different subjects, and is generated through preprocessing.

[0013] Furthermore, the process of constructing the first sentiment association analysis model and the second sentiment association analysis model includes:

[0014] Obtain initial text data and preprocess it to establish the first training set;

[0015] Fine-tune the original large language model based on the first training set to generate the first sentiment association analysis model;

[0016] A second training set is extracted from the first training set, and the first sentiment association analysis model is fine-tuned based on the second training set to generate the second sentiment association analysis model.

[0017] Furthermore, the entities include names of people, organizations and places.

[0018] Furthermore, the initial text data includes social media data and interview record data for different objects.

[0019] Furthermore, the different objects include a variety of indigenous residents, new residents, tenants, and merchants.

[0020] Furthermore, the preprocessing includes data cleaning, word segmentation, stop word removal and data labeling.

[0021] Furthermore, the fine-tuning corresponding to generating the first sentiment association analysis model is achieved based on three types of tasks: entity relationship extraction, event link prediction, and sentiment scoring.

[0022] Furthermore, the elements of the emotion vector include a happiness score, a sense of belonging score, and a sense of security score.

[0023] Furthermore, the happiness score, sense of belonging score, and sense of security score all range from -1 to 1.

[0024] The present invention also provides an electronic device comprising one or more processors, a memory and one or more programs stored in the memory, wherein the one or more programs include instructions for executing the method for identifying human-ground emotion association based on a large language model as described above.

[0025] Compared with the prior art, the present invention has the following beneficial effects:

[0026] 1. This invention uses a large language model to identify the emotional correlation between people and land. By analyzing residents' speech and emotional expressions on platforms such as social media, it can more accurately identify and understand people's daily language and emotional expressions, improving the accuracy and depth of sentiment analysis, and more accurately understanding their emotional responses to urban space. The recognition results are accurate and reliable.

[0027] 2. The method of the present invention can obtain more accurate information on the emotional correlation between people and places, quantify psychological processes, and characterize the cognition and emotional state of different groups of people towards specific places. In turn, the human-land relationship, that is, the emotional connection between people and different places in the urban space, can be considered in urban planning and renewal. This provides a new perspective and method for urban renewal, thereby guiding the planning and design of urban renewal projects, helping urban renewal projects to be more in line with residents' needs, creating urban spaces with greater emotional resonance and community identity, and promoting urban renewal to develop in a more humane and sustainable direction.

[0028] 3. Compared to traditional sentiment analysis, this method emphasizes the human-place relationship and can deeply explore and quantify the emotional connection between people and places in urban neighborhoods. This helps to better understand residents' emotional attachment to and identification with their living environment. Through big data analysis, this method can reveal the diverse emotional responses of different groups to the same location, providing urban planners with richer and more comprehensive sentiment data, and providing decision-making support for urban renewal based on data and sentiment analysis.

[0029] 4. This method can distinguish the emotional characteristics of different subjects (such as residents, businesses, tourists, etc.) and different locations, providing customized recommendations for urban renewal. By establishing a "person-place" coordinate system and quantifying psychological processes, this method can carefully distinguish and measure multiple dimensions of emotion (such as sense of belonging, security, and happiness), providing the possibility of quantifying subtle differences in emotions. This method can not only identify the positive and negative polarity of emotions, but also assess the intensity of emotions, providing a more sophisticated tool for understanding complex emotional states. BRIEF DESCRIPTION OF THE DRAWINGS

[0030] Figure 1Schematic diagram of the process of the present invention;

[0031] Figure 2 A place attachment framework in a human-place affective network constructed for embodiments of the present invention;

[0032] Figure 3 This is the process of using a large language model to perform named entity recognition in an embodiment of the present invention;

[0033] Figure 4 This is a specific process for processing input text using the fine-tuned model in an embodiment of the present invention;

[0034] Figure 5 This is the sentiment calculation process based on the large language model in an embodiment of the present invention;

[0035] Figure 6 Schematic diagram of the human-land emotional coordinate system constructed in an embodiment of the present invention. DETAILED DESCRIPTION

[0036] The present invention is described in detail below with reference to the accompanying drawings and specific embodiments. This embodiment is implemented based on the technical solution of the present invention, and provides a detailed implementation method and specific operation process, but the protection scope of the present invention is not limited to the following embodiments.

[0037] The present invention provides a method for identifying human-place emotional associations based on a large language model. Through an emotional association analysis model constructed based on the large language model, entities and emotional elements related to place attachment are extracted, and the individual's psychological process towards a specific place, including the intensity of emotion, cognition and behavior, is further quantified. An emotional vector is calculated for each individual and place, and the calculated emotional vector is analyzed to extract key features to construct a human-place emotional network map. This method deeply explores and quantifies the emotional connection between people and places in urban blocks, so as to facilitate subsequent applications in urban planning, social research and other fields.

[0038] refer to Figure 1 As shown, the above-mentioned method for identifying human-ground emotion association based on a large language model specifically includes the following steps:

[0039] Step S1, data collection and preprocessing: collect relevant text data, such as social media data, interview record data, etc., and perform preprocessing steps such as cleaning, word segmentation, and stop word removal to form the text to be recognized.

[0040] Step S2, emotional element identification: Use the first emotional association analysis model to identify and extract entities and emotional elements related to place attachment from the text to be identified. Emotional elements refer to the relationship between the extracted place attachment entities to establish place attachment emotions. Figure 2The specific embodiment of psychological processes in the framework, such as happiness, pride, love, etc. The first sentiment association analysis model is obtained by fine-tuning the open source large language model to adapt to the task of human-land association sentiment analysis.

[0041] Step S3: Quantifying Psychological Processes and Calculating Emotional Vectors: Based on the person-place coordinate system, the second emotional association analysis model is used to quantify an individual's psychological processes toward a specific place, including the intensity of emotions, cognition, and behavior. An emotional vector is calculated for each individual and place, achieving a quantitative representation of the person-place emotional association. The constructed person-place coordinate system uses the components of the emotional vector as coordinates.

[0042] Step S4: Result analysis and application: Analyze the calculated sentiment vectors, extract key features, and construct a network graph. The analysis results can be applied to fields such as urban planning and social research.

[0043] In step S1, the collected data can come from both online and offline sources. Online data is relatively extensive but not specialized enough, mainly including social media data. Offline data can more comprehensively reflect the problem. The advantage of offline data collection is that it can capture non-verbal signals, such as body language and tone, and can obtain deeper information and more authentic feedback, mainly including interview record data for different objects.

[0044] Interview transcript data is obtained from interviews. Interview questions are designed based on local context to ensure they are flexible and adaptable to the interviewees' characteristics. Interview text and audio data are collected and categorized and annotated. To best restore the human-land emotional network in urban space, data can be collected from a variety of groups, including native residents, new residents, tenants, and businesses.

[0045] For online data collection, use developer tools (such as Chrome's Inspect function) to observe network requests and responses to determine the location of the data on the page and how it is loaded. Determine the request parameters, analyze the website's search function, and find the URL structure of the search request and the required GET or POST parameters. Then, determine the keywords related to the city object being studied, such as "Hongkou District" and "Tian'ai Road", as the correct parameter configuration for the content search request. Use Python, the requests library, etc. to send network requests, parse HTML documents, and build code for network data collection. Use appropriate methods to bypass advertising data that is not related to the query content to ensure the purity of the data. Save the extracted data in an appropriate format such as CSV, JSON, or a database.

[0046] In step S2, the fine-tuned model is used to identify and extract entities and sentiment related to place attachment from the text. This can be done by either calling a local large language model or calling an online large language model, based on the choice of open-source or closed-source models. When calling a local large language model, the large language model's runtime environment should be built using the computer's graphics card (GPU) resources. Then, using an inference framework like VLLM, the large language model inference software architecture is constructed. Local APIs are then used to call the model and obtain sentiment identification results. Calling an online large language model is relatively simple, requiring only obtaining relevant credentials (such as a key) from the vendor and then building software to execute the network request.

[0047] In step S3, based on the person-place coordinate system, the model calculates and quantifies the intensity of an individual's psychological processes toward a specific place, including emotions, cognition, and behavior. Intensity here refers to the component of the emotion vector, a three-dimensional vector whose components are "sense of security," "happiness," and "belonging." The constructed three-dimensional framework of place attachment identifies three independent dimensions: person, psychological process, and place. The person dimension represents people's emotions toward a place, which can occur at both the individual and group levels. At the individual level, it involves a person's connection to a place; at the group level, attachment is the perceived symbolic meaning of a place by group members. The psychological process dimension represents people's emotional connection to a specific place, which can be positive or negative; cognitively, it relates to people's memories, beliefs, and meaning of the place; and behaviorally, individuals' actions to maintain closeness to the place, which may include return behaviors and social support. The place dimension is divided into two aspects: physical and social. The physical aspect refers to the physical characteristics of a place, such as the built environment, natural environment, and the convenient facilities or resources provided for various physical environments; the social aspect involves social ties, providing interactive social relationships and social resources, etc.

[0048] Most common natural language processing tasks derive emotional intensity from the intensity of the words. After the previous steps, we have established the basic framework of the "human-ground" coordinate system. That is, the three coordinates of the three-dimensional emotion vector can be used to establish the human-ground emotion coordinate system. Large language models can then be used to evaluate and quantify the psychological process of emotion based on this framework. Figure 6 What is shown is a basic skeleton constructed in an embodiment of the present invention, in which each person is a point in the coordinate system.

[0049] In this method, the second sentiment association analysis model is used to calculate and quantify the individual's psychological process towards a specific location. The fine-tuning process of the second sentiment association analysis model includes:

[0050] 1. Prepare a dataset of text and its corresponding psychological process labels

[0051] This process is similar to the model fine-tuning mentioned in the previous step. If the model has been fine-tuned for the human-land relationship emotion in the previous step, there is no need to fine-tune the model independently here.

[0052] 2. Clearly define tasks through prompt word engineering

[0053] The goal is to explore the psychological states reflected in the text, such as the degree of "happiness" experienced by an individual, which can be quantified by developing a scoring system. First, specific questions are designed to guide the analysis, such as: "In this text, character X's dominant emotional experience towards place Y. If we were to rate their happiness on a scale of -1 to 1, how would we rate it?" Using the answers provided by the model, the questioning format is fine-tuned and improved, and the test results are further analyzed to identify which questioning formats lead to more accurate sentiment analysis results. This optimization process may involve reframing the questions, changing the language style, or adding additional contextual information.

[0054] In step S4, the calculated sentiment vectors are analyzed to extract key features. After sorting the scores from step S4, a key feature of the human-land sentiment network can be obtained, thereby constructing a human-land associated sentiment network system to provide support for subsequent urban planning, architectural design, urban renewal, and other content.

[0055] The above method highlights the human-land relationship, can deeply explore and quantify the emotional connection between people and places in urban blocks, promote the combination of physical space renewal in urban blocks and residents' emotional memories, enhance the cohesion and vitality of the community, and provide urban planners with richer and more three-dimensional emotional data.

[0056] Example

[0057] This embodiment uses "Duolun Road" as an example to provide a method for identifying a person-land emotional association, including:

[0058] 1) Data collection and preprocessing

[0059] This example collected 72 interview audios totaling 2,600 minutes, covering a range of demographics, including indigenous residents, new residents, tenants, and businesses. Interview questions were flexibly adjusted based on the characteristics of the interviewees, allowing for dialogue to yield relatively complete data.

[0060] Sample interview questions:

[0061] 1. How long have you lived here? 2. Why did you move here? 3. Do you live with your family? 4. Can you share your experience living here? 5. What do you think the future development of this area will be like? 6. What are you dissatisfied with or would like to see updated in the space?

[0062] This example obtains video data from social networks and processes it into audio and text data in subsequent work to perform correlation analysis on "Duolun Road". The specific steps for data acquisition are as follows:

[0063] Step 1: Analyze the target website and use developer tools (such as Chrome's Inspect feature) to observe network requests and responses to determine where the data you want to obtain is on the page and how it is loaded.

[0064] Step 2: Analyze the website's search functionality to identify the URL structure and required GET or POST parameters for the search request. Determine the correct parameter configuration for the search request related to "Duolun Road."

[0065] Step 3: Use Python libraries such as requests to send network requests and parse HTML documents. Write data collection code to simulate search operations, construct a search request containing the keyword "Duolun Road," and process the returned data.

[0066] Step 4: Parse the response content and extract relevant information containing the keyword "Duolun Road", which may be video links, titles, descriptions, Douyin topics, etc. Use regular expressions or the selector function of the parsing library to locate and extract data.

[0067] Step 5. Save the extracted data in an appropriate format, such as CSV, JSON, or a database. Add error handling logic to ensure the program doesn't crash directly when encountering problems and log error information. Record logs to facilitate debugging and monitoring the program's running status.

[0068] After acquiring this data, the data is pre-processed by cleaning and other methods to remove confusing options. For example, there is a road with the same name, "Duolun Road," in Nanjing, but this road has no direct relationship with the research object of this embodiment. Therefore, Duolun Road in Nanjing needs to be excluded from the data. In addition, some video producers deliberately set a large number of tags to gain traffic. The actual content has no relationship with the "Duolun Road" to be found, which will affect the subsequent data statistical analysis process. These data need to be removed during the process.

[0069] The data acquired in this embodiment includes both text and audio data. The processing of audio data involves speech recognition technology. This embodiment uses an automatic speech recognition (ASR) system within natural language processing (NLP) to convert audio materials such as interview recordings, music, and local dialects into analyzable text data. The goal of data processing is to normalize the data and obtain a unified data base, which is then used in the NER task to generate a vector database for subsequent evaluation.

[0070] 2) Entity and Sentiment Element Recognition

[0071] In this embodiment, fine-tuning can be performed based on open-source large language models to make the large language models suitable for the human-place association sentiment analysis task. The open-source large language models used in this embodiment are such as GLM, Baichuan, etc.; closed-source large language models can also be used. The model fine-tuning is mainly decomposed into three types of tasks: entity relationship extraction, event link prediction, and sentiment scoring. In this embodiment, in the entity and relationship extraction and event extraction tasks, the DuIE2.0 (Li et al., 2019), SciERC (Luan et al., 2018), Re-TACRED (Stoica et al., 2021), and MAVEN (Wang et al., 2020) datasets are used. For the event link prediction task, we utilized the FB15K-237 (Toutanova et al., 2015) and ATOMIC 2020 (Hwang et al., 2021a) datasets. Finally, in the sentiment scoring task, the FreebaseQA (Jiang et al., 2019) and MetaQA (Zhang et al., 2018) datasets are used.

[0072] In a specific embodiment, the operation methods in the natural language (NLP) field are used to fine-tune the pre-trained model to extract entities related to place attachment from the text content, mainly including personal names and locations, so that the large language model can more accurately extract the content under the framework of the human-place relationship place attachment.

[0073] The process of fine-tuning the model requires using data that has been collected and processed manually. In this embodiment, after a large amount of data is collected, data processing is first carried out. The means of data processing include text cleaning, word segmentation, stop word removal,词性标注 (positional tagging in Chinese, which is to determine the词性 (positional) of each word (noun, verb, etc.) to provide a reference for subsequent entity recognition.

[0074] It should be noted that there is an unclear part in the original text where "词性标注" is directly in Chinese. I've translated it as "positional tagging" tentatively, but it might need to be adjusted according to the accurate English term for this concept in NLP. Also, the text in English should be further polished for better readability.When constructing a training dataset, it is necessary to ensure the quality and diversity of the dataset so that the model can learn entity labels in different contexts. It should be pointed out that the main purpose of data processing and cleaning here is to highlight the deeper parts of people and places, so as to build a more complete large model. In this step, according to the research content requirements, characters may need to be distinguished between groups and individuals, ancient people and modern people, outsiders and residents, etc. In this embodiment, the main focus is on distinguishing between individual and group memories. Use a dataset with appropriate labels to supervise the model so that the model can better adapt to the recognition of specific entities. The large language model after fine-tuning has better entity extraction capabilities than the general large language model.

[0075] like Figure 3 As shown, the GLM4 large language model is used in this embodiment, and further fine-tuning is performed on the basis of the open source GLM large model to enable the model to better adapt to recognition and extraction tasks. After that, the named entity recognition (NER) task is carried out. Through the trained model, specific types of entities, such as names of people, places, and organizations, are identified and extracted from the text. Entity recognition usually uses the BIO tagging system, where "B" represents the beginning of the entity, "I" represents the inside of the entity, and "O" represents non-entity. After this step, a relatively complete vector database has actually been obtained. The content of this vector database is close to the actual data status, and has a deeper understanding of the actual geographical and character data shown in the figure.

[0076] Figure 3 The process of named entity recognition shown can be roughly divided into: Step 1, the process of marking the text data for fine-tuning the large language model and extracting the text as BIO entities; Step 2, the process of converting the text to be recognized into vector storage; Step 3, the process of using the previously prepared large language model and vector results to extract and recognize entities from new text content.

[0077] When performing emotional element recognition, specific text is queried based on the established vector database to output the results. Figure 2 The place attachment framework shown in Figure 2, coupled with fine-tuned model building, allows for further extraction based on the content of the data. Figure 4 As shown, the text of the entity to be extracted is input into the fine-tuned model, and the text in the vector database is matched and output for correction. Figure 4 In the large language model, the operating mechanism is to predict the occurrence of the next token based on the input text. This invention formally utilizes this principle. After fine-tuning the model, it combines specific text with prompt words as input to achieve the task of extracting person-place relationship entities and simulating a person's emotions towards a place.

[0078] 3) Quantification of psychological processes and calculation of emotion vectors

[0079] This example uses the GLM4 large language model to assess the psychological process of place attachment. We extract specific emotional markers from the previously filtered data and fine-tune the model again. This study maps emotions to the three-dimensional emotional framework of place attachment. Using "happiness," "security," and "belonging" as the three axes, we use large language to score these three items, obtaining intensity values ​​between -1 and 1. This constructs the emotion vector for a person entity toward a place entity. For example, the emotion vector for a person toward a building is (0.33, 0.2, 0.3).

[0080] Through the prompt word engineering, the emotion quantification task is clearly defined. For example, if we want to know the main psychological process in the text, about the strength of "happiness", we need to design one or a series of prompt words according to the task. For example, "In this corpus, the main psychological feeling of character X towards place Y, from -1 to 1, what should the happiness be?". Based on the feedback of the model, further optimize the prompt words, analyze the test results, and identify which prompt words can produce the most accurate emotion analysis results. Optimization may include changing the question, using different language styles, or adding additional contextual information. The process is as follows: Figure 5 shown.

[0081] To ensure consistency in model output, we need to standardize the input text format, for example by cleaning the text, removing irrelevant information, or ensuring grammatical correctness. Finally, we need to evaluate the impact of different prompts on model performance and select the prompts that produce the best performance. Based on the final scoring results, we quantify the importance of human-land relationships in a more intuitive human-land relationship network, thereby constructing a place attachment factor network.

[0082] 4) Result analysis

[0083] The calculated sentiment vectors are analyzed to extract key features, and the analysis results are applied to fields such as urban planning and social research.

[0084] In this example, the happiness scores are ranked from highest to lowest by self-media, businesses, and local residents, respectively; the sense of belonging scores are ranked from highest to lowest by businesses, local residents, and self-media, respectively; and there is no significant difference in the sense of security scores. Although local residents and businesses feel attached to Duolun Road, its decline challenges the sense of happiness and belonging inherent in this place. The calculated values ​​for happiness and belonging for local residents and businesses show polarized patterns. This analysis can provide insights into the emotional network relationship between people and places for urban planning and renewal, and even architectural design.

[0085] In another implementation, human-land relationship emotional network software can be constructed based on the trained model and data. This software stores the results and provides users with access to the fine-tuned model capabilities. At the system's front-end user layer, users primarily log in, browse, and invoke the model for calculations. The control layer, while not exposed to users, is responsible for distributing user network requests to back-end services and is also a critical step in ensuring the proper operation of the system. The business layer primarily allows users to annotate data and upload it for calculations on the website.

[0086] The model calculation function in the software system is consistent with the above description of the present invention and will not be repeated here. Those skilled in the art will understand that all or part of the processes in the above-mentioned embodiment methods can be implemented by instructing the relevant hardware through a computer program, and the program can be stored in a computer-monitorable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only memory (ROM) or a random access memory (RAM).

[0087] If the above method is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, and other media that can store program code.

[0088] The above describes in detail the preferred embodiments of the present invention. It should be understood that those skilled in the art can make numerous modifications and variations based on the concepts of the present invention without inventive effort. Therefore, any technical solutions that can be derived by those skilled in the art through logical analysis, reasoning, or limited experimentation based on the concepts of the present invention and the prior art should be within the scope of protection defined by the claims.

Claims

1. A method for identifying human-ground emotion association based on a large language model, characterized in that: The following steps are involved: Get the text to be recognized; Extracting entities and sentiment elements related to place attachment from the text to be identified using a first sentiment association analysis model; Based on the person-place coordinate system and the extracted entities and sentiment elements, a second sentiment association analysis model is used to calculate the sentiment vector of each individual and place; Based on the obtained emotion vector, key features are extracted to construct a human-land emotion network map; Wherein, the first sentiment association analysis model and the second sentiment association analysis model are both constructed based on a large language model.

2. The method for identifying human-land emotion association based on a large language model according to claim 1, characterized in that: The text to be recognized is based on social media data and interview records of different objects, and is generated through preprocessing.

3. The method for identifying human-land emotion association based on a large language model according to claim 1, characterized in that: The construction process of the first sentiment association analysis model and the second sentiment association analysis model includes: Obtain initial text data and preprocess it to establish the first training set; Fine-tune the original large language model based on the first training set to generate the first sentiment association analysis model; A second training set is extracted from the first training set, and the first sentiment association analysis model is fine-tuned based on the second training set to generate the second sentiment association analysis model.

4. The method for identifying human-land emotion association based on a large language model according to claim 3 is characterized in that: The initial text data includes social media data and interview record data for different objects.

5. The method for identifying human-land emotion association based on a large language model according to claim 2 or 4, characterized in that: The different objects include various types of indigenous residents, new residents, tenants, and merchants.

6. The method for identifying human-land emotion association based on a large language model according to claim 3, characterized in that: The preprocessing includes data cleaning, word segmentation, stop word removal and data labeling.

7. The method for identifying human-ground emotion association based on a large language model according to claim 3, characterized in that: The fine-tuning corresponding to generating the first sentiment association analysis model is achieved based on three types of tasks: entity relationship extraction, event link prediction and sentiment scoring.

8. The method for identifying human-land emotion association based on a large language model according to claim 1, characterized in that: The elements of the emotion vector include a happiness score, a sense of belonging score, and a sense of security score.

9. The method for identifying human-ground emotion association based on a large language model according to claim 1, characterized in that: The happiness score, sense of belonging score, and sense of security score all range from -1 to 1.

10. An electronic device, characterized in that: It includes one or more processors, a memory and one or more programs stored in the memory, wherein the one or more programs include instructions for executing the method for identifying human-ground emotion association based on a large language model as described in any one of claims 1-9.

Citation Information

Cited By

  • Dialogue sentiment classification method and device based on previous screening and example reasoning

    CN120234421A

  • A method and device for conversation sentiment classification based on context screening and example reasoning

    CN120234421B