Thematic Categorization on Pineapple Production in C osta R ica: An Exploratory Analysis through Topic Modeling (2025)

Abstract: Costa Rica is one of the largest producers and exporters of pineapple in the world. This status has encouraged multinational companies to use plantations in this Central American country for experimentation and the cultivation of new varieties, such as the Pinkglow pineapple. However, pineapple monoculture has significant socio-environmental impacts on the regions where it is cultivated.In this exploratory study, we aimed to analyze how pineapple production is portrayed on the Internet. To achieve this, we collected a corpus of texts in Spanish and English from online sources in two phases: using the BootCat tool and manual search on newspaper websites. The Hierarchical Dirichlet Process (HDP) topic model was then applied to identify dominant topics within the corpus. These topics were subsequently classified into thematic categories, and the texts were categorized accordingly. The findings indicate that environmental issues related to pineapple cultivation are underrepresented on the Internet, particularly in comparison to the extensive focus on topics related to pineapple production and marketing.

## introduction pineapples are widely available in supermarkets across europe, japan, and the united states. this tropical fruit is cultivated in several countries, with costa rica ranking as one of the leading producers and exporters @xcite . while pineapple production has generated significant revenue for companies in costa rica, it has also raised concerns regarding its impact on labor rights @xcite @xcite and the environment. numerous academic and ngo studies have documented the environmental and health damage caused by pineapple monocultures in costa rica. the adverse environmental effects stem primarily from the use of pesticides, which contaminate water and soil, thereby affecting humans, animals, and plants @xcite . additionally, these effects result from the excessive use of water for irrigation, which depletes wetlands and underground water reserves @xcite . finally, monoculture practices leave the land over-exploited and depleted of essential nutrients @xcite . these issues are emblematic of the current geological epoch: the anthropocene (de cózar, 2019). a notable example of the anthropocene is the creation of the pink pineapple (known as pinkglow) in costa rica. this new variety was developed in the laboratories of the del monte company, which holds the patent for it @xcite . the distinctive pink coloration serves purely aesthetic purposes, catering to a market heavily driven by visual appeal. due to its high market value, the pink pineapple is exclusively marketed outside of costa rica @xcite , where it is promoted as an exotic product from a tropical country. in this context, an interdisciplinary group initiated a study on the relationship between pineapple plantations and the territory, as well as the representation of the pineapple-particularly the pinkglow variety-as a cultural object. within this framework, we sought to explore the topics circulating on the internet about pineapple production and costa rica and to examine whether there are differences between texts in spanish and english. to address these goals, we aim to apply advances in natural language processing (nlp), specifically topic modeling, to identify the thematic categories present in the corpus of digital texts. accordingly, the objective of this exploratory research is to identify and categorize, through topic modeling, the thematic categories associated with pineapple production in costa rica within a corpus comprising diverse textual genres. numerous studies have applied natural language processing (nlp) techniques to address environmental issues. some focus on identifying and geographically mapping the impacts of climate change by analyzing academic papers and scholarly articles @xcite or through sentiment analysis @xcite @xcite , and stance classification in tweets @xcite or news articles @xcite . additionally, efforts have been made to create datasets related to environmental topics, such as ecoverse, an english twitter dataset for eco-relevance classification, stance detection, and environmental impact analysis @xcite ; gercct, a german twitter dataset for argument mining (schaefer and @xcite ; and climatext, a dataset for detecting topics related to climate change @xcite . in addition, several studies have applied topic modeling techniques within the environmental domain. these include research on climate change discussions in social media @xcite @xcite , correlations between topics and sentiment in news articles @xcite @xcite , analyses of nature and science editorials @xcite , and targeted journal publications @xcite , as well as research and policy papers @xcite . topic modeling has also been applied to election manifestos and parliamentary debates @xcite . although the aforementioned studies provided a foundation, our exploratory research adopted a distinct thematic and methodological approach. specifically, we examined pineapple production across various textual genres, compared topics and thematic categories between english and spanish, and implemented the topic model that yielded the highest coherence score (hdp). ## method the method used consists of five phases (see figure 1 ). first, the corpus was extracted and retrieved through two stages: second, a manual corpus analysis was conducted to remove irrelevant texts (e.g., incomplete texts, texts without mentions of pineapples or the pinkglow variety, and empty texts) and to classify textual genres (see ## analysis the hdp model dynamically determines the number of topics. for our data, it identified 73 topics for the sds and 137 topics for the eds. of the 73 topics in the sds, 50 were dominant, while of the 137 topics in the eds, only 41 were dominant. the dominant topics in both subsets were classified according to pre-established and emerging categories (see figure 2 ). it is important to note that a single topic could correspond to multiple categories. the results (figure 5 and on the other hand, a greater variety of dominant topics is observed in the sds compared to the eds. in the sds, only two thematic categories lacked a dominant topic, and nine dominant topics could not be classified into any category. in contrast, in the eds, five thematic categories remained unassigned, and only four dominant topics were unclassified. the results (figure 6 ) indicate that the thematic category 'pineapple production' appears in the greatest number of sds texts, with 61 occurrences, representing 41% of the total occurrences across all thematic categories (149 occurrences). this finding suggests that the majority of the spanish texts predominantly address aspects of pineapple production. this is somewhat expected, as the majority of the dominant topics (21 topics) were classified under this thematic category. in second place, the thematic category 'consumption food-aesthetic' appeared in 38 texts (26%). despite being composed of only eight dominant topics, this category's frequency of occurrence is noteworthy. on the other hand, in the eds, the results show that the dominant topics in most texts belong to the thematic category 'consumption food-aesthetic' (50 occurrences, 47%), followed by 'pineapple production' (26 occurrences, 24%). this suggests that the content of most eds texts focuses on consuming pineapples in general, and pinkglow in particular. this is consistent with the fact that the majority of the dominant topics (25 topics) were classified under this thematic category. however, it is notable that 24% of texts (26 occurrences) feature dominant topics related to 'pineapple production,' despite being represented by only five topics. additionally, the category 'contamination' appears in just 10 texts (9%), further emphasizing the thematic focus of the eds. each dominant topic contributes a different percentage within each text. this contribution reflects the extent to which the topic is represented in the text, thereby indicating its importance in terms of coverage or reiteration. for this reason, we chose to examine the percentage contribution of topics within each thematic category across the texts where they were dominant. considering the thematic categories with the highest number of texts ('pineapple production,' 'other,' 'consumption food-aesthetic,' and 'sales'), the results show that in the sds, the topics within the 'consumption food-aesthetic' category (80%) contribute the most to the texts when dominant, as their average contribution exceeds that of the other categories (figure 7 ). this is followed by 'sales' (77%) and 'pineapple production' (75%), while 'other' has the lowest average contribution (65%). these results suggest that when the 'consumption food-aesthetic' category appears, its topics occupy a greater proportion of the text or are repeated more frequently, indicating a stronger presence compared to other topics within the same text. additionally, the high average (80%) suggests that the primary topics in these texts are more specific in nature. finally, the average contribution of the dominant topics in the 'other' thematic category (65%) is the lowest among the four categories with the highest number of texts. it is important to refrain from providing detailed explanations for this result, as the 'other' category encompasses a wide range of topics. as a result, the content of these texts may vary significantly, therefore it would not be advisable to analyze them as a group. in the eds (figure 8 ), two thematic categories clearly group the largest number of texts: 'pineapple production' and 'consumption food-aesthetic.' the mean for 'pineapple production' (75%) suggests that, in the texts where its topics are dominant, there is a greater thematic specialization compared to 'consumption food-aesthetic' (73%). nevertheless, the topics in both thematic categories contribute over 70% on average in most of the texts in which they are dominant. this substantial contribution indicates a significant presence of these topics, either through their thematic focus or repeated mention within the texts. ## discussion the results indicate that in most texts from both subsets, the most frequent categories are 'pineapple production' and 'consumption: food-aesthetic'. however, the subsets differ in their dominant thematic categories. in the sds, the most frequent category is 'pineapple production', whereas in the eds, 'consumption: food-aesthetic' is predominant. this distinction suggests that english-language texts circulating on the internet focus more on promoting pineapple consumption, including products such as pinkglow. conversely, spanish-language texts more frequently address topics related to pineapple production. this difference can be attributed to the fact that pineapples are produced in several latin american countries (e.g., costa rica, ecuador, cuba, nicaragua) and represent an important export product, particularly in costa rica. consequently, spanish-language texts prioritize production-related themes over the promotion of consumption. on the other hand, englishlanguage texts have broader international reach, as english is the primary language for global marketing communication. therefore, it is unsurprising that 'consumption: food-aesthetic' appears more frequently in english-language texts. in both the sds and eds, references to environmental topics are minimal. when combining categories such as 'contamination', 'erosion', 'lack of water', 'climate change', and 'health problems', these topics constitute only 9% in the sds and 13% in the eds. this finding indicates that most online texts in spanish and english fail to address the serious environmental issues caused by pineapple monoculture in latin american countries, particularly in costa rica. instead, the internet perpetuates an image of pineapples as an appealing fruit for consumption, obscuring the environmental consequences of their production. such an image may not only bolster a positive perception of pineapples but also introduce biases for researchers working with internet-based datasets on this topic. it is important to note that computational models perform more accurately with english texts than with spanish texts. this discrepancy may influence the results, which can only be validated through human review. while such a process is slow and labor-intensive, it is essential for improving computational models and the research relying on them. the thematic categories were developed based on texts addressing pineapple production and marketing in costa rica. the classification of dominant topics within each category was derived from the ten most frequent words foot_2 associated with each topic. however, the analysis did not involve a thorough review of the content of individual texts to confirm the alignment of the dominant topics with the thematic categories. consequently, there was no human verification to ensure that: (1) the dominant topics were consistent with the main themes or frequent words in the texts, and (2) the primary topics in the texts aligned with the thematic categories used in the research. to address these limitations, future studies should incorporate human verification steps to confirm the relationship between topics, keywords, and the content of the texts. future research could also focus on improving the methodology in several ways. first, the corpus should be expanded, as the number of texts collected for this study was relatively small compared to the volume of texts available online. alternative methods for collecting online texts should be explored. second, the research scope could be broadened to include other agricultural products from costa rica, such as bananas, cocoa, coffee, and palm. this expanded scope would increase the corpus size and help determine whether the low prevalence of environmental topics is consistent across other crops. third, new categories could be added for corpus classification, such as main topics, perspectives and source ideologies. depending on the size of the corpus, a dataset could be created to train computational models to classify texts according to these new categories. this approach would provide greater clarity regarding the relationship between topics, content, perspectives, and sources. finally, sentiment analysis could be integrated to assess the sentiment associated with different topics and thematic categories. this would allow researchers to identify the probable sentiment of various themes and assign it to the thematic categories more systematically. lastly, it should be noted that due to space constraints, this paper does not present the results for the most frequent words or the relationship between textual genres and thematic categories. ## conclusion following this exploratory study, we conclude that combining the application of hierarchical dirichlet processes (hdp) with the human construction of thematic categories could effectively identify the main content patterns in texts across different languages. the findings suggest that significant environmental and labor rights issues associated with pineapple production are rarely disseminated on the internet. this lack of coverage hinders the visibility of the environmental and health problems caused by pineapple monocultures and pesticide use in costa rica and other producing countries. furthermore, this scarcity of information contributes to a lack of awareness among global consumers, who continue to purchase pineapples and represent a potential market for new laboratory-developed variants created by corporations. despite the insights gained, it is important to acknowledge the limitations of this exploratory study when interpreting the results and considering directions for future research. first, the corpus obtained through web scraping was relatively small, limiting the generalization of the findings. second, we have not yet conducted a human evaluation of the assignment of dominant topics to individual texts, which would provide a more robust verification of topic classification within the thematic categories.