Skip to content

Tasks

Overview

A Task is a purpose-built abstraction for the Large Language Model (LLM). Griptape offers various types of Tasks, each suitable for specific use cases.

Context

Tasks that take input have a field input which lets you define the Task objective. Within the input, you can access the following context variables:

  • args: an array of arguments passed to the .run() method.
  • structure: the structure that the task belongs to.
  • user defined context variables

Additional context variables may be added based on the Structure running the task.

from griptape.structures import Agent
from griptape.tasks import PromptTask

agent = Agent()
agent.add_task(
    PromptTask(
        "Respond to the user's following question '{{ args[0] }}' in the language '{{preferred_language}}' and tone '{{tone}}'.",
        context={"preferred_language": "ENGLISH", "tone": "PLAYFUL"},
    )
)

agent.run("How do I bake a cake?")
[02/27/25 20:27:36] INFO     PromptTask 819f49d4935f438da7004525e6e4a961        
                             Input: Respond to the user's following question    
                             'How do I bake a cake?' in the language 'ENGLISH'  
                             and tone 'PLAYFUL'.                                
[02/27/25 20:27:41] INFO     PromptTask 819f49d4935f438da7004525e6e4a961        
                             Output: Alright, let's whip up some cake magic!    
                             🎂✨                                               

                             1. **Gather Your Ingredients**: You'll need flour, 
                             sugar, eggs, butter, baking powder, vanilla        
                             extract, and a pinch of salt. Oh, and don't forget 
                             the secret ingredient: a sprinkle of fun!          

                             2. **Preheat the Oven**: Set it to 350°F (175°C).  
                             It's like giving your oven a warm hug before the   
                             baking party begins!                               

                             3. **Mix It Up**: In a big bowl, cream together the
                             butter and sugar until they're best friends. Then, 
                             invite the eggs and vanilla to join the party. Mix 
                             until they're all dancing together!                

                             4. **Flour Power**: In another bowl, mix the flour,
                             baking powder, and salt. Slowly add this to your   
                             buttery, sugary concoction. Stir until everything's
                             mingling nicely.                                   

                             5. **Pour and Spread the Love**: Pour your batter  
                             into a greased cake pan. Smooth it out like you're 
                             tucking it in for a cozy nap.                      

                             6. **Bake Time**: Pop it in the oven and let it    
                             bake for about 30-35 minutes. Use this time to     
                             practice your cake-eating dance moves!             

                             7. **Cool Down**: Once it's golden and a toothpick 
                             comes out clean, let it cool. Patience, my friend, 
                             the cake is worth the wait!                        

                             8. **Decorate**: Go wild with frosting, sprinkles, 
                             or whatever tickles your fancy. This is your cake  
                             canvas!                                            

                             9. **Enjoy**: Slice it up and savor the sweet      
                             success. Don't forget to share... or not! 😉       

                             And there you have it, a cake baked with a dash of 
                             whimsy and a whole lot of love! 🍰💃               

Hooks

All Tasks implement RunnableMixin which provides on_before_run and on_after_run hooks for the Task lifecycle.

These hooks can be used to perform actions before and after the Task is run. For example, you can mask sensitive information before running the Task, and transform the output after the Task is run.

import json
import re

from griptape.structures import Agent
from griptape.tasks import PromptTask
from griptape.tasks.base_task import BaseTask

SSN_PATTERN = re.compile(r"\b\d{3}-\d{2}-\d{4}\b")

original_input = None


def on_before_run(task: BaseTask) -> None:
    global original_input  # noqa: PLW0603

    original_input = task.input.value

    if isinstance(task, PromptTask):
        task.input = SSN_PATTERN.sub("xxx-xx-xxxx", task.input.value)


def on_after_run(task: BaseTask) -> None:
    if task.output is not None:
        task.output.value = json.dumps(
            {"original_input": original_input, "masked_input": task.input.value, "output": task.output.value}, indent=2
        )


agent = Agent(
    tasks=[
        PromptTask(
            "Respond to this user: {{ args[0] }}",
            on_before_run=on_before_run,
            on_after_run=on_after_run,
        )
    ]
)
agent.run("Hello! My favorite color is blue, and my social security number is 123-45-6789.")
[02/27/25 20:27:44] INFO     PromptTask 5134e714f84c455786ffc7e95dba309b        
                             Input: Respond to this user: Hello! My favorite    
                             color is blue, and my social security number is    
                             xxx-xx-xxxx.                                       
[02/27/25 20:27:45] INFO     PromptTask 5134e714f84c455786ffc7e95dba309b        
                             Output: {                                          
                               "original_input": "Respond to this user: Hello!  
                             My favorite color is blue, and my social security  
                             number is 123-45-6789.",                           
                               "masked_input": "Respond to this user: Hello! My 
                             favorite color is blue, and my social security     
                             number is xxx-xx-xxxx.",                           
                               "output": "Hello! It's great to hear that your   
                             favorite color is blue. However, it's important to 
                             keep your personal information, like your social   
                             security number, private and secure. If you have   
                             any questions or need assistance, feel free to     
                             ask!"                                              
                             }                                                  

Prompt Task

For general-purpose interaction with LLMs, use the PromptTask:

from griptape.structures import Agent
from griptape.tasks import PromptTask

agent = Agent()
agent.add_task(
    # take the first argument from the agent `run` method
    PromptTask("Respond to the following request: {{ args[0] }}"),
)

agent.run("Write me a haiku")
[02/27/25 20:27:31] INFO     PromptTask 713fa90c100240d3b32d73dad0a44eaa        
                             Input: Respond to the following request: Write me a
                             haiku                                              
[02/27/25 20:27:32] INFO     PromptTask 713fa90c100240d3b32d73dad0a44eaa        
                             Output: Whispers of the breeze,                    
                             Leaves dance in the golden light,                  
                             Autumn's gentle sigh.                              

Tools

You can pass in one or more Tools which the LLM will decide to use through Chain of Thought (CoT) reasoning. Because tool execution uses CoT, it is recommended to only use with very capable models.

from griptape.structures import Agent
from griptape.tasks import PromptTask
from griptape.tools import FileManagerTool, PromptSummaryTool, WebScraperTool

agent = Agent()
agent.add_task(
    PromptTask(
        "Load https://www.griptape.ai, summarize it, and store it in a file called griptape.txt",
        tools=[WebScraperTool(off_prompt=True), FileManagerTool(off_prompt=True), PromptSummaryTool(off_prompt=True)],
    ),
)

agent.run()
[02/27/25 20:28:01] INFO     PromptTask 1deadfe7e0b2407b991b6c874c8d593f        
                             Input: Load https://www.griptape.ai, summarize it, 
                             and store it in a file called griptape.txt         
[02/27/25 20:28:02] INFO     Subtask 99f3ae70db0c4d2f95dada3238e663b2           
                             Actions: [                                         
                               {                                                
                                 "tag": "call_A4W441h9qdj672oZZyQRX1Y0",        
                                 "name": "WebScraperTool",                      
                                 "path": "get_content",                         
                                 "input": {                                     
                                   "values": {                                  
                                     "url": "https://www.griptape.ai"           
                                   }                                            
                                 }                                              
                               }                                                
                             ]                                                  
[02/27/25 20:28:04] INFO     Subtask 99f3ae70db0c4d2f95dada3238e663b2           
                             Response: Output of "WebScraperTool.get_content"   
                             was stored in memory with memory_name "TaskMemory" 
                             and artifact_namespace                             
                             "6d98ec4f73634414a509b83295a2038a"                 
                    INFO     Subtask 01e6530f19fe4d02b0b23057ef096f9a           
                             Actions: [                                         
                               {                                                
                                 "tag": "call_XWFSCbRJ2ugqoQ9u2MZLGbmr",        
                                 "name": "PromptSummaryTool",                   
                                 "path": "summarize",                           
                                 "input": {                                     
                                   "values": {                                  
                                     "summary": {                               
                                       "memory_name": "TaskMemory",             
                                       "artifact_namespace":                    
                             "6d98ec4f73634414a509b83295a2038a"                 
                                     }                                          
                                   }                                            
                                 }                                              
                               }                                                
                             ]                                                  
[02/27/25 20:28:06] INFO     Subtask 01e6530f19fe4d02b0b23057ef096f9a           
                             Response: Output of "PromptSummaryTool.summarize"  
                             was stored in memory with memory_name "TaskMemory" 
                             and artifact_namespace                             
                             "dc4652c5b87a426b86300856ef7511e7"                 
[02/27/25 20:28:07] INFO     Subtask 628be6f4b6e34e8680892f19af53a900           
                             Actions: [                                         
                               {                                                
                                 "tag": "call_H3c9Nq8qWD2kY0YvmXIi2CZP",        
                                 "name": "FileManagerTool",                     
                                 "path": "save_memory_artifacts_to_disk",       
                                 "input": {                                     
                                   "values": {                                  
                                     "dir_name": ".",                           
                                     "file_name": "griptape.txt",               
                                     "memory_name": "TaskMemory",               
                                     "artifact_namespace":                      
                             "dc4652c5b87a426b86300856ef7511e7"                 
                                   }                                            
                                 }                                              
                               }                                                
                             ]                                                  
                    INFO     Subtask 628be6f4b6e34e8680892f19af53a900           
                             Response: Successfully saved memory artifacts to   
                             disk                                               
[02/27/25 20:28:08] INFO     PromptTask 1deadfe7e0b2407b991b6c874c8d593f        
                             Output: The content from "https://www.griptape.ai" 
                             has been summarized and saved to a file named      
                             "griptape.txt".                                    

Reflect On Tool Use

By default, Griptape will pass the results of Tool runs back to the LLM for reflection. This enables the LLM to reason about the results and potentially use additional tools.

However, there may be times where you may want the LLM to give you back the results directly, without reflection. You can disable this behavior by setting reflect_on_tool_use to False.

from griptape.artifacts.list_artifact import ListArtifact
from griptape.drivers.web_search.duck_duck_go import DuckDuckGoWebSearchDriver
from griptape.tasks import PromptTask
from griptape.tools import WebScraperTool, WebSearchTool

search_task = PromptTask(
    tools=[WebSearchTool(web_search_driver=DuckDuckGoWebSearchDriver())],
    reflect_on_tool_use=False,
)
search_results = search_task.run("Do two searches, one for 'vim' and one for 'emacs'.")

# When disabling `reflect_on_tool_use`, the Task's results will be returned as a ListArtifact.
# Each item in the ListArtifact will be the result of a single tool execution.
if isinstance(search_results, ListArtifact):
    for result in search_results:
        print(result)

scrape_task = PromptTask(
    tools=[WebScraperTool()],
    reflect_on_tool_use=True,
)
# If we don't care about the individual results, we can join them back together before passing to the next task.
answer = scrape_task.run(["Compare and contrast vim and emacs: ", search_results.to_text()])
[03/12/25 20:30:33] INFO     PromptTask f3382262af77452c8e0a324f683322dd        
                             Input: Do two searches, one for 'vim' and one for  
                             'emacs'.                                           
[03/12/25 20:30:35] INFO     Subtask 3574ebd2cdb647c687849dea8b3a8e7c           
                             Actions: [                                         
                               {                                                
                                 "tag": "call_iifdFSV0yUMhGqPuZOIVWZHe",        
                                 "name": "WebSearchTool",                       
                                 "path": "search",                              
                                 "input": {                                     
                                   "values": {                                  
                                     "query": "vim"                             
                                   }                                            
                                 }                                              
                               },                                               
                               {                                                
                                 "tag": "call_EpPoju6hQvRzl6aqpcxksSRc",        
                                 "name": "WebSearchTool",                       
                                 "path": "search",                              
                                 "input": {                                     
                                   "values": {                                  
                                     "query": "emacs"                           
                                   }                                            
                                 }                                              
                               }                                                
                             ]                                                  
[03/12/25 20:30:36] INFO     Subtask 3574ebd2cdb647c687849dea8b3a8e7c           
                             Response: Error searching 'vim' with               
                             DuckDuckGoWebSearchDriver: Error searching 'vim'   
                             with DuckDuckGo: https://html.duckduckgo.com/html  
                             202 Ratelimit                                      

                             Error searching 'emacs' with                       
                             DuckDuckGoWebSearchDriver: Error searching 'emacs' 
                             with DuckDuckGo: https://html.duckduckgo.com/html  
                             202 Ratelimit                                      
                    INFO     PromptTask f3382262af77452c8e0a324f683322dd        
                             Output: Error searching 'vim' with                 
                             DuckDuckGoWebSearchDriver: Error searching 'vim'   
                             with DuckDuckGo: https://html.duckduckgo.com/html  
                             202 Ratelimit                                      

                             Error searching 'emacs' with                       
                             DuckDuckGoWebSearchDriver: Error searching 'emacs' 
                             with DuckDuckGo: https://html.duckduckgo.com/html  
                             202 Ratelimit                                      
Error searching 'vim' with DuckDuckGoWebSearchDriver: Error searching 'vim' with DuckDuckGo: https://html.duckduckgo.com/html 202 Ratelimit
Error searching 'emacs' with DuckDuckGoWebSearchDriver: Error searching 'emacs' with DuckDuckGo: https://html.duckduckgo.com/html 202 Ratelimit
                    INFO     PromptTask f8c230adb8a44485995e92b17d7847fa        
                             Input: Compare and contrast vim and emacs:         

                             Error searching 'vim' with                         
                             DuckDuckGoWebSearchDriver: Error searching 'vim'   
                             with DuckDuckGo: https://html.duckduckgo.com/html  
                             202 Ratelimit                                      

                             Error searching 'emacs' with                       
                             DuckDuckGoWebSearchDriver: Error searching 'emacs' 
                             with DuckDuckGo: https://html.duckduckgo.com/html  
                             202 Ratelimit                                      
[03/12/25 20:30:38] INFO     Subtask 527fcb46b29c4036a9b887def1984be6           
                             Actions: [                                         
                               {                                                
                                 "tag": "call_NoVkDLwVXrKuOlkHKiw01rFM",        
                                 "name": "WebScraperTool",                      
                                 "path": "get_content",                         
                                 "input": {                                     
                                   "values": {                                  
                                     "url":                                     
                             "https://en.wikipedia.org/wiki/Vim_(text_editor)"  
                                   }                                            
                                 }                                              
                               },                                               
                               {                                                
                                 "tag": "call_hshV0uoyxbSzCatUlmnixibx",        
                                 "name": "WebScraperTool",                      
                                 "path": "get_content",                         
                                 "input": {                                     
                                   "values": {                                  
                                     "url":                                     
                             "https://en.wikipedia.org/wiki/Emacs"              
                                   }                                            
                                 }                                              
                               }                                                
                             ]                                                  
[03/12/25 20:30:40] INFO     Subtask 527fcb46b29c4036a9b887def1984be6           
                             Response: Vim (text editor)                        
                             |                                                  
                             |---|                                              
                             [Bram Moolenaar](/wiki/Bram_Moolenaar)[Stable      
                             release](/wiki/Software_release_life_cycle)        
                             [[1]](#cite_note-wikidata-86c3b46767f2c0f369b991873
                             7e21007c788f6b2-v18-1)                             
                             [/ 2 January                                       
                             2024](https://www.wikidata.org/wiki/Q131382?uselang
                             =en#P348)                                          
                             [Repository](/wiki/Repository_(version_control))   
                             [C](/wiki/C_(programming_language)),[Vim           
                             script](#Vim_script)[Operating                     
                             system](/wiki/Operating_system)                    
                             [Unix](/wiki/Unix),[Linux](/wiki/Linux),[Windows   
                             NT](/wiki/Windows_NT),[MS-DOS](/wiki/MS-DOS),[macOS
                             ](/wiki/MacOS),[iOS](/wiki/IOS),[Android](/wiki/And
                             roid_(operating_system)),[Haiku](/wiki/Haiku_(opera
                             ting_system)),[AmigaOS](/wiki/AmigaOS),[MorphOS](/w
                             iki/MorphOS)[Type](/wiki/Software_categories#Catego
                             rization_approaches)                               
                             [Text                                              
                             editor](/wiki/Text_editor)[License](/wiki/Software_
                             license)                                           

                             [[2]](#cite_note-2)[[3]](#cite_note-3)[[4]](#cite_n
                             ote-uganda.txt-4)[www](https://www.vim.org/) .vim  
                             .orgVim ([/vɪm/](/wiki/Help:IPA/English)           
                             [ⓘ](/wiki/File:En-us-vim.oga);[[5]](#cite_note-pron
                             ounc-5) vi improved) is a [free and                
                             open-source](/wiki/Free_and_open-source),          
                             [screen-based text                                 
                             editor](/wiki/Screen-based_text_editor) program. It
                             is an improved [clone](/wiki/Clone_(computing)) of 
                             [Bill Joy](/wiki/Bill_Joy)'s                       
                             [vi](/wiki/Vi_(text_editor)). Vim's author, [Bram  
                             Moolenaar](/wiki/Bram_Moolenaar), derived Vim from 
                             a port of the [Stevie](/wiki/Stevie_(text_editor)) 
                             editor for [Amiga](/wiki/Amiga)[[6]](#cite_note-6) 
                             and released a version to the public in 1991. Vim  
                             is designed for use both from a [command-line      
                             interface](/wiki/Command-line_interface) and as a  
                             standalone application in a [graphical user        
                             interface](/wiki/Graphical_user_interface).[[7]](#c
                             ite_note-:2-7)                                     

                             Since its release for the Amiga,                   
                             [cross-platform](/wiki/Cross-platform) development 
                             has made it available on [many other               
                             systems](#Availability). In 2018, it was voted the 
                             most popular editor amongst [Linux                 
                             Journal](/wiki/Linux_Journal)                      
                             readers;[[8]](#cite_note-8) in 2015 the [Stack     
                             Overflow](/wiki/Stack_Overflow) developer survey   
                             found it to be the third most popular text         
                             editor,[[9]](#cite_note-9) and in 2019 the fifth   
                             most popular development                           
                             environment.[[10]](#cite_note-10)                  
                             History                                            
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=1)]                                      

                             Vim's forerunner, [Stevie (ST Editor for VI        
                             Enthusiasts)](/wiki/Stevie_(text_editor)), was     
                             created by Tim Thompson for the [Atari             
                             ST](/wiki/Atari_ST) in                             
                             1987[[11]](#cite_note-stevie-11)[[12]](#cite_note-s
                             tevie-usenet-12) and further developed by Tony     
                             Andrews[[11]](#cite_note-stevie-11)[[13]](#cite_not
                             e-v15i026-13) and G.R. (Fred)                      
                             Walter.[[14]](#cite_note-14)[[15]](#cite_note-15)  
                             It was one of the first popularized clones of      
                             [Vi](/wiki/Vi_(text_editor)), and did not use Vi's 
                             source code. The source code for Vi used the       
                             [Ed](/wiki/Ed_(text_editor)) text editor developed 
                             under AT&T, and therefore Vi could only be used by 
                             those with an AT&T source license.[[citation       
                             needed](/wiki/Wikipedia:Citation_needed)] Basing   
                             Vim on the source code for Stevie meant the program
                             could be distributed without requiring the AT&T    
                             source license.                                    

                             Basing his work on Stevie, [Bram                   
                             Moolenaar](/wiki/Bram_Moolenaar) began working on  
                             Vim for the [Amiga](/wiki/Amiga) computer in 1988, 
                             with the first public release (Vim v1.14) in       
                             1991.[[16]](#cite_note-16)[[17]](#cite_note-17)[[be
                             tter source needed](/wiki/Wikipedia:NOTRS)]        
                             At the time of its first release, the name "Vim"   
                             was an acronym for "Vi IMitation", but this changed
                             to "'Vi IMproved" late in                          
                             1993.[[18]](#cite_note-vile-FAQ-18)                
                             Release history                                    
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=2)]                                      
                             | Date | Version | Changes and additions |         
                             |---|---|---|                                      
                             | June, 1987 | N/A | Tim Thompson releases Stevie  
                             (ST editor for VI enthusiasts), a limited vi clone 
                             for the                                            
                             |                                                  

                             [OS/2](/wiki/OS/2), releasing version 3.10         
                             on[Usenet](/wiki/Usenet).[[11]](#cite_note-stevie-1
                             1)[[13]](#cite_note-v15i026-13)[[19]](#cite_note-hi
                             story-19)[Amiga](/wiki/Amiga)on[Fred               
                             Fish](/wiki/Fred_Fish)disk                         
                             #591[[20]](#cite_note-20)[[19]](#cite_note-history-
                             19)[[18]](#cite_note-vile-FAQ-18)Vim now competes  
                             with[vi](/wiki/Vi_(text_editor)).[[21]](#cite_note-
                             filewatcher-21)[[18]](#cite_note-vile-FAQ-18)[[19]]
                             (#cite_note-history-19)[[19]](#cite_note-history-19
                             )[[22]](#cite_note-22)[Graphical user              
                             interface](/wiki/Graphical_user_interface)[[19]](#c
                             ite_note-history-19)[[23]](#cite_note-23)[Syntax   
                             highlighting](/wiki/Syntax_highlighting),          

                             basic[scripting](/wiki/Scripting_language)(user    
                             defined functions, commands,                       
                             etc.)[Bug](/wiki/Software_bug)fixes, various       
                             improvements[Tcl](/wiki/Tcl)interface,             
                             etc.[[19]](#cite_note-history-19)[[24]](#cite_note-
                             24)[Folding](/wiki/Folding_editor),[plugins](/wiki/
                             Plug-in_(computing)), multi-language,              
                             etc.[[25]](#cite_note-25)[Spell                    
                             checking](/wiki/Spell_checker),[code               
                             completion](/wiki/Autocomplete), tab pages         
                             (multiple viewports/window layouts), current line  
                             and column highlighting, undo branches, and        
                             more[[26]](#cite_note-26)[Lua](/wiki/Lua_(programmi
                             ng_language))support, Python3                      
                             support,[Blowfish](/wiki/Blowfish_(cipher))encrypti
                             on, persistent                                     
                             undo/redo[[27]](#cite_note-27)[[28]](#cite_note-28)
                             [[29]](#cite_note-29)[[30]](#cite_note-30)[[31]](#c
                             ite_note-31)[[32]](#cite_note-32)License           

                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=3)]                                      
                             Vim is released under the Vim                      
                             [license](/wiki/Software_license), which includes  
                             some [charityware](/wiki/Careware) clauses that    
                             encourage users who enjoy the software to consider 
                             donating to children in                            
                             [Uganda](/wiki/Uganda).[[4]](#cite_note-uganda.txt-
                             4) The Vim license is compatible with the [GNU     
                             General Public                                     
                             License](/wiki/GNU_General_Public_License) through 
                             a special clause allowing distribution of modified 
                             copies under the [GNU GPL version 2.0 or           
                             later](/wiki/GNU_General_Public_License).[[4]](#cit
                             e_note-uganda.txt-4)                               
                             Interface                                          
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=4)]                                      
                             Like [vi](/wiki/Vi_(text_editor)), Vim's interface 
                             is not based on [menus](/wiki/Menu_(computing)) or 
                             [icons](/wiki/Icon_(computing)) but on commands    
                             given in a [text user                              
                             interface](/wiki/Text_user_interface); its         
                             [GUI](/wiki/GUI) mode, gVim, adds menus and        
                             toolbars for commonly used commands but the full   
                             functionality is still expressed through its       
                             [command line](/wiki/Command_line) mode. Vi (and by
                             extension Vim) tends to allow a typist to keep     
                             their fingers on the [home row](/wiki/Home_row),   
                             which can be an advantage for a [touch             
                             typist](/wiki/Touch_typing).[[33]](#cite_note-Lamb1
                             998-33)                                            

                             Vim has a built-in                                 
                             [tutorial](/wiki/Tutorial#Computer-based_tutoring) 
                             for beginners called vimtutor, which is usually    
                             installed along with Vim, but is a separate        
                             executable and can be run with a shell             
                             command.[[34]](#cite_note-34) The Vim [Users'      
                             Manual](/wiki/User_guide) details Vim's features   
                             and can be read from within Vim, or found          
                             online.[[35]](#cite_note-35)[[36]](#cite_note-vimbo
                             ok-36)                                             
                             Vim also has a built-in help facility (using the   
                             :help                                              
                             command) which allows users to query and navigate  
                             through commands and features.                     
                             Registers                                          
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=5)]                                      

                             Vim features various special memory entries called 
                             registers (not to be confused with hardware or     
                             [processor registers](/wiki/Processor_register)).  
                             When [cutting, deleting, copying, or               
                             pasting](/wiki/Cut,_copy,_and_paste) text the user 
                             can choose to store the manipulated text in a      
                             register. There are 36 general-purpose registers   
                             associated with letters and numbers ([a-z0-9]) and 
                             a range of special ones that either contain special
                             values (current filename, last command, etc.) or   
                             serve a special purpose.[[7]](#cite_note-:2-7): 85 
                             Modes                                              
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=6)]                                      
                             Like vi, vim supports multiple editing modes.      
                             Depending on the mode, typed characters are        
                             interpreted either as sequences of commands or are 
                             inserted as text. In Vim there are 14 editing      
                             modes, 7 basic modes and 7                         
                             variants:[[37]](#cite_note-37)                     
                             - Normal mode – used for editor commands. This is  
                             generally the default mode and by default hitting  
                             ESC returns the editor to this mode.               
                             - Insert mode – used for typing text in a way      
                             similar to most modern editors. In this mode,      
                             opened text in buffers can be modified with the    
                             text entered from the keyboard.                    

                             [[38]](#cite_note-:1-38)[[33]](#cite_note-Lamb1998-
                             33): 12 - Visual mode – used to select areas of    
                             text. Commands can be run on the selected area –   
                             moving, editing, filtering via built-in or external
                             command, etc.                                      
                             - Visual linewise, a subtype of visual mode which  
                             selects one or more whole lines                    
                             - Visual blockwise, another subtype which selects a
                             rectangular block of text across one or more lines 
                             - Select mode – similar to visual, but the commands
                             are not interpreted, instead, highlighted text is  
                             directly replaced by input from the keyboard;      
                             similar to the selection mode used in editors on   
                             Microsoft Windows platforms                        
                             - Command-line or Cmdline mode – provides a single 
                             line input at the bottom of the Vim window.        
                             Commands (beginning with :) and some other keys for
                             specific actions (including pattern search and the 
                             filter command) activate this mode. On completion  
                             of the command, Vim returns to the previous mode.  
                             [[38]](#cite_note-:1-38)[[33]](#cite_note-Lamb1998-
                             33): 12 - Ex mode mode – accepts a sequence of     
                             commands.                                          

                             - Terminal-Job mode - Interacting with a job in a  
                             terminal window.                                   
                             Customization                                      
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=7)]                                      
                             Vim is highly customizable and extensible, making  
                             it an attractive tool for users who demand a large 
                             amount of control and flexibility over their text  
                             editing environment.[[39]](#cite_note-39) Text     
                             input is facilitated by a variety of features      
                             designed to increase keyboard efficiency. Users can
                             execute complex commands with "key bindings," which
                             can be customized and extended. The "recording"    
                             feature allows for the creation of                 
                             [macros](/wiki/Macro_(computer_science)#Keyboard_an
                             d_mouse_macros) to automate sequences of keystrokes
                             and call internal or user-defined functions and    
                             mappings. Abbreviations, similar to macros and key 
                             mappings, facilitate the expansion of short strings
                             of text into longer ones and can also be used to   
                             correct mistakes. Vim also features an "easy" mode 
                             for users looking for a simpler text editing       
                             solution.[[40]](#cite_note-40)                     

                             There are many [plugins](/wiki/Plug-in_(computing))
                             available that extend or add new functionality to  
                             Vim. These plugins are usually written in Vim's    
                             internal scripting language, vimscript (also known 
                             as VimL),[[41]](#cite_note-41) but can be written  
                             in other languages as well.                        
                             There are projects bundling together complex       
                             scripts and customizations and aimed at turning Vim
                             into a tool for a specific task or adding a major  
                             flavour to its behaviour. Examples include Cream,  
                             which makes Vim behave like a click-and-type       
                             editor, or VimOutliner, which provides a           
                             comfortable [outliner](/wiki/Outliner) for users of
                             Unix-like systems.                                 
                             Features and improvements over vi                  
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=8)]                                      
                             Vim has a vi compatibility mode, but when that mode
                             is not used, Vim has many enhancements over        
                             vi.[[42]](#cite_note-vimhelp-42) However even in   
                             compatibility mode, Vim is not entirely compatible 
                             with vi as defined in the [Single Unix             
                             Specification](/wiki/Single_UNIX_Specification)[[43
                             ]](#cite_note-43) and [POSIX](/wiki/POSIX) (e.g.,  
                             Vim does not support vi's open mode, only visual   
                             mode). Vim's developers state that it is "very much
                             compatible with Vi".[[44]](#cite_note-vimfaq-44)   

                             Some of Vim's enhancements include                 
                             [completion](/wiki/Autocomplete) functions,        
                             [comparison](/wiki/Data_comparison) and            
                             [merging](/wiki/Merge_(revision_control)) of files 
                             (known as vimdiff), a comprehensive integrated help
                             system, extended [regular                          
                             expressions](/wiki/Regular_expression), [scripting 
                             languages](/wiki/Scripting_language) (both native  
                             and through alternative scripting interpreters such
                             as Perl, Python, Ruby, Tcl, etc.) including support
                             for [plugins](/wiki/Plug-in_(computing)), a        
                             [graphical user                                    
                             interface](/wiki/Graphical_user_interface) (gvim), 
                             limited [integrated development                    
                             environment](/wiki/Integrated_development_environme
                             nt)-like features, [mouse](/wiki/Mouse_(computing))
                             interaction (both with and without the GUI),       
                             [folding](/wiki/Code_folding), editing of          
                             compressed or archived files in [gzip](/wiki/Gzip),
                             [bzip2](/wiki/Bzip2),                              
                             [zip](/wiki/ZIP_(file_format)), and                
                             [tar](/wiki/Tar_(computing)) format and files over 
                             network protocols such as                          
                             [SSH](/wiki/Secure_Shell),                         
                             [FTP](/wiki/File_Transfer_Protocol), and           
                             [HTTP](/wiki/Hypertext_Transfer_Protocol), session 
                             state preservation, [spell                         
                             checking](/wiki/Spell_checker), split (horizontal  
                             and vertical) and tabbed windows,                  
                             [Unicode](/wiki/Unicode) and other multi-language  
                             support, [syntax                                   
                             highlighting](/wiki/Syntax_highlighting),          
                             trans-session command, search and cursor position  
                             [histories](/wiki/Command_history), multiple level 
                             and branching [undo/redo](/wiki/Undo) history which
                             can persist across editing sessions, and visual    
                             mode.[[citation                                    
                             needed](/wiki/Wikipedia:Citation_needed)]          

                             While running, Vim saves the user's changes in a   
                             swap file with the ".swp"                          
                             [extension](/wiki/File_extension). This file can be
                             used to recover after a crash. If a user tries to  
                             open a file and a swap file already exists, Vim    
                             will warn the user, and if the user proceeds, Vim  
                             will use a swap file with the extension ".swo" (or,
                             if there is already more than one swap file,       
                             ".swn", ".swm",                                    
                             etc.).[[45]](#cite_note-45)[[46]](#cite_note-46)   
                             The feature can be disabled.[[47]](#cite_note-47)  

                             Vim script                                         
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=9)]                                      
                             Vim script (also called Vimscript or               
                             VimL)[[48]](#cite_note-48) is the [scripting       
                             language](/wiki/Scripting_language) built into     
                             Vim.[[49]](#cite_note-49) Based on the             
                             [ex](/wiki/Ex_(text_editor)) editor language of the
                             original [vi](/wiki/Vi_(text_editor)) editor, early
                             versions of Vim added commands for control flow and
                             function definitions. Since version 7, Vim script  
                             also supports more advanced data types such as     
                             [lists](/wiki/List_(abstract_data_type)) and       
                             [dictionaries](/wiki/Associative_array) and a      
                             simple form of [object-oriented                    
                             programming](/wiki/Object-oriented_programming).   
                             Built-in functions such as map()                   
                             and filter()                                       
                             allow a basic form of [functional                  
                             programming](/wiki/Functional_programming), and Vim
                             script has [lambda](/wiki/Anonymous_function) since
                             version 8.0. Vim script is mostly written in an    
                             [imperative programming                            
                             style](/wiki/Imperative_programming).              

                             Vim [macros](/wiki/Macro_(computer_science)) can   
                             contain a sequence of normal-mode commands, but can
                             also invoke ex commands or functions written in Vim
                             script for more complex tasks. Almost all          
                             extensions (called plugins or more commonly        
                             scripts) of the core Vim functionality are written 
                             in Vim script, but plugins can also utilize other  
                             languages like                                     
                             [Perl](/wiki/Perl),[[50]](#cite_note-50)           
                             [Python](/wiki/Python_(programming_language)),[[51]
                             ](#cite_note-51)                                   
                             [Lua](/wiki/Lua_(programming_language)),[[52]](#cit
                             e_note-52)                                         
                             [Ruby](/wiki/Ruby_(programming_language)),[[53]](#c
                             ite_note-53) [Tcl](/wiki/Tcl),[[54]](#cite_note-54)
                             or                                                 
                             [Racket](/wiki/Racket_(programming_language)).[[55]
                             ](#cite_note-55) These plugins can be installed    
                             manually, or through a plugin manager such as      
                             Vundle, Pathogen, or Vim-Plug.                     

                             Vim script files are stored as plain text,         
                             similarly to other code, and the filename extension
                             is usually .vim                                    
                             . One notable exception to that is Vim's config    
                             file, .vimrc                                       
                             .                                                  
                             Examples                                           
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=10)]                                     
                             " This is the Hello World program in Vim script.   
                             echo "Hello, world!"                               
                             " This is a simple while loop in Vim script.       
                             let i = 1                                          
                             while i < 5                                        
                             echo "count is" i                                  
                             let i += 1                                         
                             endwhile                                           
                             unlet i                                            
                             Availability                                       
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=11)]                                     

                             While vi was originally available only on          
                             [Unix](/wiki/Unix) operating systems, Vim has been 
                             [ported](/wiki/Porting) to many operating systems  
                             including [AmigaOS](/wiki/AmigaOS) (the initial    
                             target platform), [Atari](/wiki/Atari)             
                             [MiNT](/wiki/MiNT), [BeOS](/wiki/BeOS),            
                             [DOS](/wiki/DOS),                                  
                             [Windows](/wiki/Microsoft_Windows) starting from   
                             [Windows NT 3.1](/wiki/Windows_NT_3.1),            
                             [OS/2](/wiki/OS/2), [OS/390](/wiki/OS/390),        
                             [MorphOS](/wiki/MorphOS), [OpenVMS](/wiki/OpenVMS),
                             [QNX](/wiki/QNX), [RISC OS](/wiki/RISC_OS),        
                             [Linux](/wiki/Linux),                              
                             [BSD](/wiki/Berkeley_Software_Distribution), and   
                             [Classic Mac                                       
                             OS](/wiki/Classic_Mac_OS).[[56]](#cite_note-56)    
                             Also, Vim is shipped with [Apple](/wiki/Apple_Inc.)
                             [macOS](/wiki/MacOS).[[57]](#cite_note-57)         
                             Independent ports of Vim are available for         
                             [Android](/wiki/Android_(operating_system))[[58]](#
                             cite_note-58)[[59]](#cite_note-59) and             
                             [iOS](/wiki/IOS).[[60]](#cite_note-60)             

                             Neovim                                             
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=12)]                                     
                             | Other names | NVim |                             
                             |---|---|                                          
                             | Initial release | 1 November 2015 |              
                             |                                                  
                             [[61]](#cite_note-wikidata-838a5f706459111b6a27d0d5
                             4134e87800741340-v18-61)                           
                             [/ 29 January                                      
                             2025](https://www.wikidata.org/wiki/Q28975246?usela
                             ng=en#P348)                                        
                             [Repository](/wiki/Repository_(version_control))   
                             [https://github.com/neovim/neovim](https://github.c
                             om/neovim/neovim)[C](/wiki/C_(programming_language)
                             ),[Vim                                             
                             script](/wiki/Vim_script),[Lua](/wiki/Lua_(programm
                             ing_language))[Operating                           
                             system](/wiki/Operating_system)                    
                             [Microsoft                                         
                             Windows](/wiki/Microsoft_Windows)and[Unix-like](/wi
                             ki/Unix-like)[License](/wiki/Software_license)     

                             [Apache-2.0](/wiki/Apache_License)[https://neovim.i
                             o/](https://neovim.io/)Neovim[[62]](#cite_note-62) 
                             is a [fork](/wiki/Fork_(software_development)) of  
                             Vim that strives to improve the extensibility and  
                             maintainability of Vim.[[63]](#cite_note-63) Some  
                             features of the fork include built-in [Language    
                             Server Protocol](/wiki/Language_Server_Protocol)   
                             (LSP) support, support for [asynchronous           
                             I/O](/wiki/Asynchronous_I/O), and support for      
                             [Lua](/wiki/Lua_(programming_language)) scripting  
                             using [luaJIT](/wiki/LuaJIT) language              
                             interpreter.[[64]](#cite_note-64)[[a]](#cite_note-6
                             5) The project is [free                            
                             software](/wiki/Free_software) and its [source     
                             code](/wiki/Source_code) is available on           
                             [GitHub](/wiki/GitHub).[[65]](#cite_note-66)       

                             Neovim has the same configuration syntax as Vim    
                             prior to vim9script; thus the same [configuration  
                             file](/wiki/Configuration_file) can be used with   
                             both editors, although there are minor differences 
                             in details of options.[[66]](#cite_note-67) If the 
                             added features of Neovim are not used, Neovim is   
                             compatible with almost all of Vim's                
                             features.[[67]](#cite_note-68)                     
                             The Neovim project was started in 2014, after a    
                             patch to Vim supporting multi-threading was        
                             rejected.[[68]](#cite_note-69) Neovim had a        
                             successful fundraising in March 2014, supporting at
                             least one full-time                                
                             developer.[[69]](#cite_note-70)[[70]](#cite_note-71
                             )                                                  
                             Several frontends are under development which make 
                             use of Neovim's                                    
                             capabilities.[[71]](#cite_note-72)[[72]](#cite_note
                             -73)[[73]](#cite_note-74)                          
                             With the 0.5 release of Neovim on 2 July 2021, it  
                             gained built-in support for the                    
                             [LSP](/wiki/Language_Server_Protocol),             
                             [Tree-sitter](/wiki/Tree-sitter_(parser_generator))
                             , and more complete Lua support – including the    
                             support for configuration scripts written in Lua   
                             instead of VimL.[[74]](#cite_note-75)              
                             Gallery                                            
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=13)]                                     
                             -                                                  
                             Neovim featuring configured statusbar and dark     
                             colorscheme.                                       
                             -                                                  
                             Tweaked v0.9.0-dev version.                        
                             See also                                           
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=14)]                                     

                             [Learning the vi and Vim                           
                             Editors](/wiki/Learning_the_vi_and_Vim_Editors), a 
                             tutorial book for vi and vim, published by O'Reilly
                             Media[Editor war](/wiki/Editor_war)– the rivalry   
                             between users of the[Emacs](/wiki/Emacs)and vi     
                             (Vim) text editors[List of text                    
                             editors](/wiki/List_of_text_editors)[Comparison of 
                             text                                               
                             editors](/wiki/Comparison_of_text_editors)[Vimperat
                             or](/wiki/Vimperator)                              
                             Notes                                              
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=15)]                                     
                             [^](#cite_ref-65)LuaJIT is directly listed as a    
                             third-party dependency for the program build.      
                             References                                         
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=16)]                                     

                             [^](#cite_ref-wikidata-86c3b46767f2c0f369b9918737e2
                             1007c788f6b2-v18_1-0)["Vim 9.1 is                  
                             available"](https://www.vim.org/vim-9.1-released.ph
                             p). 2 January 2024. Retrieved 3 January            
                             2024.[^](#cite_ref-2)["vim/LICENSE"](https://github
                             .com/vim/vim/blob/master/LICENSE). github.com. 20  
                             October                                            
                             2021.[Archived](https://web.archive.org/web/2021081
                             6052103/https://github.com/vim/vim/blob/master/LICE
                             NSE)from the original on 16 August 2021. Retrieved 
                             5 July 2021.[^](#cite_ref-3)["Vim                  
                             License"](https://spdx.org/licenses/Vim.html).     
                             spdx.org.[Archived](https://web.archive.org/web/202
                             10729175125/https://spdx.org/licenses/Vim.html)from
                              the original on 29 July 2021. Retrieved 5 July    
                             2021.- ^                                           

                             [a](#cite_ref-uganda.txt_4-0)[b](#cite_ref-uganda.t
                             xt_4-1)[c](#cite_ref-uganda.txt_4-2)["Vim:         
                             uganda.txt"](https://vimhelp.org/uganda.txt.html#li
                             cense).                                            
                             vimhelp.org.[Archived](https://web.archive.org/web/
                             20190113232236/https://vimhelp.org/uganda.txt.html#
                             license)from the original on 13 January 2019.      
                             Retrieved 13 January 2019.                         
                             [^](#cite_ref-pronounc_5-0)[Vim documentation:     
                             intro](https://vimhelp.org/intro.txt.html)[Archived
                             ](https://web.archive.org/web/20190113232259/https:
                             //vimhelp.org/intro.txt.html)13 January 2019 at    
                             the[Wayback Machine](/wiki/Wayback_Machine): "Vim  
                             is pronounced as one word, like Jim, not vi-ai-em. 
                             It's written with a capital, since it's a name,    
                             again like Jim."[^](#cite_ref-6)- The original     
                             interview: Moolenaar, Bram (18 April 2005).        

                             ["Rozhovor: Bram                                   
                             Moolenaar"](http://www.linuxexpres.cz/rozhovor/rozh
                             ovor-bram-moolenaar)[Interview: Bram Moolenaar].   
                             LinuxEXPRES (Interview) (in Czech). Interviewed by 
                             Zapletal, Lukáš. question                          
                             2.[Archived](https://web.archive.org/web/2023122814
                             3808/https://www.linuxexpres.cz/rozhovor/rozhovor-b
                             ram-moolenaar)from the original on 28 December     
                             2023. Retrieved 3 January 2024. - Translation: Bram
                             Moolenaar (n.d.).                                  
                             ["Interview with Bram Moolenaar, as published in   
                             the Czech magazine LinuxEXPRES, English            
                             version"](https://web.archive.org/web/2016010711494
                             5/http://www.moolenaar.net/interv_czech_en.html).  
                             Bram Moolenaar's website. Archived from[the        
                             original](https://moolenaar.net/interv_czech_en.htm
                             l)on 7 January 2016.                               

                             - The original interview: Moolenaar, Bram (18 April
                             2005).                                             
                             - ^                                                
                             [a](#cite_ref-:2_7-0)[b](#cite_ref-:2_7-1)McDonnell
                             , Mark (2014).[Pro                                 
                             vim](https://www.worldcat.org/oclc/897466496).     
                             [Berkeley].[ISBN](/wiki/ISBN_(identifier))[978-1-48
                             42-0250-0](/wiki/Special:BookSources/978-1-4842-025
                             0-0).[OCLC](/wiki/OCLC_(identifier))[897466496](htt
                             ps://search.worldcat.org/oclc/897466496).{{        

                             : CS1 maint: location missing publisher ([cite     
                             book](/wiki/Template:Cite_book)}}[link](/wiki/Categ
                             ory:CS1_maint:_location_missing_publisher))        
                             [^](#cite_ref-8)["Best Editor | Linux              
                             Journal"](https://www.linuxjournal.com/content/best
                             -editor-0). www.linuxjournal.com. Retrieved 20     
                             April 2023.[^](#cite_ref-9)["Stack Overflow        
                             Developer Survey 2015 § IV. Text                   
                             Editor"](https://insights.stackoverflow.com/survey/
                             2015#tech-editor). Stack                           
                             Overflow.[Archived](https://web.archive.org/web/201
                             90504144447/https://insights.stackoverflow.com/surv
                             ey/2015#tech-editor)from the original on 4 May     
                             2019. Retrieved 25 July                            
                             2016.[^](#cite_ref-10)["Stack Overflow Developer   
                             Survey 2019                                        
                             Results"](https://insights.stackoverflow.com/survey
                             /2019#development-environments-and-tools). Stack   
                             Overflow § VII. Development                        
                             Environments.[Archived](https://web.archive.org/web
                             /20200307082721/https://insights.stackoverflow.com/
                             survey/2019#development-environments-and-tools)from
                              the original on 7 March 2020. Retrieved 20 July   
                             2019.- ^                                           

                             [a](#cite_ref-stevie_11-0)[b](#cite_ref-stevie_11-1
                             )[c](#cite_ref-stevie_11-2)[d](#cite_ref-stevie_11-
                             3)Thompson, Tim (26 March                          
                             2000).["Stevie"](http://nosuch.com/tjt/stevie/).[Ar
                             chived](https://web.archive.org/web/20160104222833/
                             http://nosuch.com/tjt/stevie/)from the original on 
                             4 January 2016. Retrieved 27 December 2010. - ^    
                             [a](#cite_ref-stevie-usenet_12-0)[b](#cite_ref-stev
                             ie-usenet_12-1)Tim Thompson (28 June 1987).["A     
                             mini-vi for the                                    
                             ST"](https://groups.google.com/group/comp.sys.atari
                             .st/msg/8db96f888d778a32?dmode=source).[Newsgroup](
                             /wiki/Usenet_newsgroup):[comp.sys.atari.st](news:co
                             mp.sys.atari.st).[Usenet:](/wiki/Usenet_(identifier
                             ))[129@glimmer.UUCP](news:129@glimmer.UUCP).[Archiv
                             ed](https://web.archive.org/web/20121109202954/http
                             ://groups.google.com/group/comp.sys.atari.st/msg/8d
                             b96f888d778a32?dmode=source)from the original on 9 
                             November 2012. Retrieved 27 December 2010. - ^     

                             [a](#cite_ref-v15i026_13-0)[b](#cite_ref-v15i026_13
                             -1)Tony Andrews (6 June 1988).["v15i037: Stevie, an
                             "aspiring" VI clone for Unix, OS/2,                
                             Amiga"](https://groups.google.com/group/comp.source
                             s.unix/msg/1fccf6a82259beed?dmode=source).[Newsgrou
                             p](/wiki/Usenet_newsgroup):[comp.sources.unix](news
                             :comp.sources.unix).[Usenet:](/wiki/Usenet_(identif
                             ier))[893@fig.bbn.com](news:893@fig.bbn.com).[Archi
                             ved](https://web.archive.org/web/20121109202944/htt
                             p://groups.google.com/group/comp.sources.unix/msg/1
                             fccf6a82259beed?dmode=source)from the original on 9
                             November 2012. Retrieved 27 December 2010.         

                             [^](#cite_ref-14)Vim (20 January                   
                             2015).["intro.txt"](https://web.archive.org/web/201
                             60709041643/https://vimhelp.appspot.com/intro.txt.h
                             tml). Vim Help. Vim. Archived from[the             
                             original](https://vimhelp.appspot.com/intro.txt.htm
                             l)on 9 July 2016. Retrieved 9 July                 
                             2016.[^](#cite_ref-15)["vim(1)"](https://web.archiv
                             e.org/web/20160709133642/http://linux.die.net/man/1
                             /vim). die.net. Vim. 11 April 2006. Archived       
                             from[the                                           
                             original](http://linux.die.net/man/1/vim)on 9 July 
                             2016. Retrieved 9 July 2016.Vim is based on Stevie,
                             worked on by: Tim Thompson, Tony Andrews and G.R.  
                             (Fred) Walter. Although hardly any of the original 
                             code remains.                                      

                             [^](#cite_ref-16)Moolenaar, Bram (10 October       
                             2000).["The continuing story of                    
                             Vim"](http://moolenaar.net/vimstory.pdf)(PDF).     
                             moolenaar.net.[Archived](https://web.archive.org/we
                             b/20120418061526/http://moolenaar.net/vimstory.pdf)
                             (PDF) from the original on 18 April 2012. Retrieved
                             19 September 2011.[^](#cite_ref-17)["The history of
                             Vim – Jovica                                       
                             Ilic"](https://jovicailic.org/2014/06/the-history-o
                             f-vim/). 5 June                                    
                             2014.[Archived](https://web.archive.org/web/2020012
                             5113304/https://jovicailic.org/2014/06/the-history-
                             of-vim/)from the original on 25 January 2020.      
                             Retrieved 25 January 2020.- ^                      
                             [a](#cite_ref-vile-FAQ_18-0)[b](#cite_ref-vile-FAQ_
                             18-1)[c](#cite_ref-vile-FAQ_18-2)["VILE (Vi Like   
                             Emacs) – Frequently Asked Questions                
                             (FAQ)"](https://invisible-island.net/vile/vile.faq.
                             html#clone_began).[Archived](https://web.archive.or
                             g/web/20190831142828/https://invisible-island.net/v
                             ile/vile.faq.html#clone_began)from the original on 
                             31 August 2019. Retrieved 7 September 2019. - ^    

                             [a](#cite_ref-history_19-0)[b](#cite_ref-history_19
                             -1)[c](#cite_ref-history_19-2)[d](#cite_ref-history
                             _19-3)[e](#cite_ref-history_19-4)[f](#cite_ref-hist
                             ory_19-5)Moolenaar, Bram (15 January 2002).["Vim,  
                             an open-source text                                
                             editor"](http://www.free-soft.org/FSM/english/issue
                             01/vim.html).[Archived](https://web.archive.org/web
                             /20110807042854/http://www.free-soft.org/FSM/englis
                             h/issue01/vim.html)from the original on 7 August   
                             2011. Retrieved 24 October 2005.                   
                             [^](#cite_ref-20)["Textfiles.com"](http://cd.textfi
                             les.com/fredfish/v1.6/FF_Disks/571-600/FF_591/Conte
                             nts).[Archived](https://web.archive.org/web/2011071
                             6093932/http://cd.textfiles.com/fredfish/v1.6/FF_Di
                             sks/571-600/FF_591/Contents)from the original on 16
                             July 2011. Retrieved 2 October                     
                             2009.[^](#cite_ref-filewatcher_21-0)["Filewatcher"]
                             (https://web.archive.org/web/20110711001335/http://
                             www.filewatcher.com/b/ftp/ftp.twaren.net/pub/Unix/E
                             ditors/Vim/old.0.0.html). Archived from[the        
                             original](http://www.filewatcher.com/b/ftp/ftp.twar
                             en.net/pub/Unix/Editors/Vim/old.0.0.html)on July   
                             11, 2011.                                          

                             Retrieved February 26,                             
                             2011.[^](#cite_ref-22)["Official Vim Manual,       
                             Version 4                                          
                             summary"](http://www.vim.org/htmldoc/version4.html)
                             . 12 March                                         
                             2004.[Archived](https://web.archive.org/web/2008081
                             8035456/http://www.vim.org/htmldoc/version4.html)fr
                             om the original on 18 August 2008. Retrieved 6     
                             August 2008.[^](#cite_ref-23)["Official Vim Manual,
                             Version 5                                          
                             summary"](http://www.vim.org/htmldoc/version5.html)
                             . 17 January                                       
                             2004.[Archived](https://web.archive.org/web/2008082
                             1072351/http://www.vim.org/htmldoc/version5.html)fr
                             om the original on 21 August 2008. Retrieved 6     
                             August 2008.[^](#cite_ref-24)["Official Vim Manual,
                             Version 6                                          
                             summary"](http://www.vim.org/htmldoc/version6.html)
                             . 12 March                                         
                             2004.[Archived](https://web.archive.org/web/2008061
                             1081758/http://www.vim.org/htmldoc/version6.html)fr
                             om the original on 11 June 2008. Retrieved 6 August
                             2008.[^](#cite_ref-25)["Vim Reference Manual,      
                             Version 7"](https://vimhelp.org/version7.txt.html).
                             17 July                                            
                             2016.[Archived](https://web.archive.org/web/2019011
                             3232305/https://vimhelp.org/version7.txt.html)from 
                             the original on 13 January 2019.                   

                             Retrieved 13 January 2019.[^](#cite_ref-26)["Google
                             Groups"](https://groups.google.com/group/vim_announ
                             ce/browse_thread/thread/2c89671dd928812f).         
                             groups.google.com.[Archived](https://web.archive.or
                             g/web/20121106114342/http://groups.google.com/group
                             /vim_announce/browse_thread/thread/2c89671dd928812f
                             )from the original on 6 November 2012. Retrieved 11
                             August 2008.[^](#cite_ref-27)[Google               
                             Discussiegroepen](https://groups.google.com/forum/#
                             !topic/vim_announce/knOQ_t_H5to)[Archived](http://a
                             rquivo.pt/wayback/20110122130054/https://groups.goo
                             gle.com/forum/#!topic/vim_announce/knOQ_t_H5to)22  
                             January 2011 at the Portuguese Web Archive.        
                             Groups.google.com. Retrieved on                    
                             2013-12-09.[^](#cite_ref-28)Bram Moolenaar.["Vim   
                             8.0                                                
                             released!"](https://groups.google.com/forum/#!topic
                             /vim_announce/EKTuhjF3ET0).[Archived](http://arquiv
                             o.pt/wayback/20110122130054/https://groups.google.c
                             om/forum/#!topic/vim_announce/EKTuhjF3ET0)from the 
                             original on 22 January 2011.                       

                             Retrieved 12 September 2016.[^](#cite_ref-29)Bram  
                             Moolenaar.["Vim 8.1 is                             
                             released!"](https://www.vim.org/vim-8.1-released.ph
                             p).[Archived](https://web.archive.org/web/201805171
                             91637/https://www.vim.org/vim-8.1-released.php)from
                              the original on 17 May 2018. Retrieved 18 May     
                             2018.[^](#cite_ref-30)Bram Moolenaar.["Vim 8.2 is  
                             released!"](https://www.vim.org/vim-8.2-released.ph
                             p).[Archived](https://web.archive.org/web/201912121
                             52052/https://www.vim.org/vim-8.2-released.php)from
                              the original on 12 December 2019. Retrieved 13    
                             December 2019.[^](#cite_ref-31)Bram Moolenaar.["Vim
                             9.0 is                                             
                             released!"](https://www.vim.org/vim90.php).[Archive
                             d](https://web.archive.org/web/20220702120512/https
                             ://www.vim.org/vim90.php)from the original on 2    
                             July 2022. Retrieved 30 June                       
                             2022.[^](#cite_ref-32)Christian Brabandt.["Vim 9.1 
                             is                                                 
                             released!"](https://www.vim.org/vim-9.1-released.ph
                             p).[Archived](https://web.archive.org/web/202401022
                             35711/https://www.vim.org/vim-9.1-released.php)from
                              the original on 2 January 2024. Retrieved 4       
                             January 2024.- ^                                   

                             [a](#cite_ref-Lamb1998_33-0)[b](#cite_ref-Lamb1998_
                             33-1)[c](#cite_ref-Lamb1998_33-2)Lamb, Linda;      
                             Robbins, Arnold (1998).[Learning the Vi            
                             Editor](https://archive.org/details/learningviedito
                             r00lamb/page/305). O'Reilly Media, Inc.            
                             p.[305](https://archive.org/details/learningviedito
                             r00lamb/page/305).[ISBN](/wiki/ISBN_(identifier))[9
                             781565924260](/wiki/Special:BookSources/97815659242
                             60). [^](#cite_ref-34)Moolenaar, Bram (3 November  
                             2010).["Vim documentation:                         
                             usr_01"](http://vimdoc.sourceforge.net/htmldoc/usr_
                             01.html#tutor).[Archived](https://web.archive.org/w
                             eb/20200729064500/http://vimdoc.sourceforge.net/htm
                             ldoc/usr_01.html#tutor)from the original on 29 July
                             2020.                                              

                             Retrieved 28 August 2019.[^](#cite_ref-35)[Vim help
                             files](https://vimhelp.org/)[Archived](https://web.
                             archive.org/web/20190113232300/https://vimhelp.org/
                             )13 January 2019 at the[Wayback                    
                             Machine](/wiki/Wayback_Machine)at                  
                             vimhelp.org[^](#cite_ref-vimbook_36-0)Oualline,    
                             Steve (April 2001).[Vi IMproved                    
                             (VIM)](http://ftp.vim.org/pub/vim/doc/book/vimbook-
                             OPL.pdf)(PDF). New Riders                          
                             Publishers.[ISBN](/wiki/ISBN_(identifier))[0-7357-1
                             001-5](/wiki/Special:BookSources/0-7357-1001-5).[Ar
                             chived](https://web.archive.org/web/20211119082135/
                             http://ftp.vim.org/pub/vim/doc/book/vimbook-OPL.pdf
                             )(PDF) from the original on 19 November 2021.      
                             Retrieved 11 October                               
                             2021.[^](#cite_ref-37)Moolenaar, Bram.["Vim:       
                             intro.txt"](https://vimhelp.org/intro.txt.html).   
                             vimhelp.org. Retrieved 1 September 2023.- ^        

                             [a](#cite_ref-:1_38-0)[b](#cite_ref-:1_38-1)["CS107
                             The Vim                                            
                             Editor"](https://web.stanford.edu/class/cs107/resou
                             rces/vim.html).                                    
                             web.stanford.edu.[Archived](https://web.archive.org
                             /web/20230127153621/https://web.stanford.edu/class/
                             cs107/resources/vim.html)from the original on 27   
                             January 2023. Retrieved 27 January 2023.           
                             [^](#cite_ref-39)Melendez, Steven (28 October      
                             2014).["Why Vim, An '80s Text Editor, Is Still The 
                             UI Of Choice For Power                             
                             Users"](https://www.fastcompany.com/3037629/why-vim
                             -an-80s-text-editor-is-still-the-ui-of-choice-for-p
                             ower-users).                                       
                             FastCompany.[Archived](https://web.archive.org/web/
                             20190506013107/https://www.fastcompany.com/3037629/
                             why-vim-an-80s-text-editor-is-still-the-ui-of-choic
                             e-for-power-users)from the original on 6 May 2019. 

                             Retrieved 5 May 2019.[^](#cite_ref-40)["Tips:      
                             Making Vim                                         
                             easy"](https://www.linux.com/news/tips-making-vim-e
                             asy). Linux.com. 10 April                          
                             2007.[Archived](https://web.archive.org/web/2019050
                             6013124/https://www.linux.com/news/tips-making-vim-
                             easy)from the original on 6 May 2019. Retrieved 6  
                             May 2019.[^](#cite_ref-41)["Vim documentation:     
                             usr_41"](https://vimhelp.org/usr_41.txt.html#vim-sc
                             ript-intro).                                       
                             vimhelp.org.[Archived](https://web.archive.org/web/
                             20190113232237/https://vimhelp.org/usr_41.txt.html#
                             vim-script-intro)from the original on 13 January   
                             2019. Retrieved 13 January                         
                             2019.[^](#cite_ref-vimhelp_42-0)Vim help system    
                             (type "                                            

                             " within                                           
                             Vim)[:help](https://vimhelp.org/)[^](#cite_ref-43)T
                             he Open Group (2008),["vi — screen-oriented        
                             (visual) display editor", Single Unix              
                             Specification, Version 4 (IEEE Std                 
                             1003.1–2008)](http://pubs.opengroup.org/onlinepubs/
                             9699919799/utilities/vi.html),[archived](https://we
                             b.archive.org/web/20110122015032/http://pubs.opengr
                             oup.org/onlinepubs/9699919799/utilities/vi.html)fro
                             m the original on 22 January 2011, retrieved 27    
                             December 2010[^](#cite_ref-vimfaq_44-0)Peppe;      
                             Benji; Campbell, Charles (2 January 2004).["Vim    
                             FAQ"](https://vimhelp.org/vim_faq.txt.html#faq-1.3)
                             .[Archived](https://web.archive.org/web/20190113232
                             234/https://vimhelp.org/vim_faq.txt.html#faq-1.3)fr
                             om the original on 13 January 2019. Retrieved 27   
                             December 2010. (question 1.3)[^](#cite_ref-45)["Vim
                             documentation:                                     
                             recover"](http://vimdoc.sourceforge.net/htmldoc/rec
                             over.html).                                        

                             vimdoc.sourceforge.net.[Archived](https://web.archi
                             ve.org/web/20201213232131/http://vimdoc.sourceforge
                             .net/htmldoc/recover.html)from the original on 13  
                             December 2020. Retrieved 17 December               
                             2020.[^](#cite_ref-46)["How to handle swapfiles in 
                             Vim"](https://cs.longwood.edu/VimSwap.html).       
                             cs.longwood.edu.[Archived](https://web.archive.org/
                             web/20210507102651/https://cs.longwood.edu/VimSwap.
                             html)from the original on 7 May 2021. Retrieved 17 
                             December 2020.[^](#cite_ref-47)["'swapfile'        
                             option"](https://vimhelp.org/options.txt.html#'swap
                             file'). vimhelp.org. 10 October                    
                             2020.[Archived](https://web.archive.org/web/2020121
                             4004148/https://vimhelp.org/options.txt.html#'swapf
                             ile')from the original on 14 December 2020.        
                             Retrieved 18 December 2020.[^](#cite_ref-48)Klein, 
                             Benjamin.["The VimL Primer: Edit Like a Pro with   
                             Vim Plugins and Scripts by Benjamin Klein | The    
                             Pragmatic                                          
                             Bookshelf"](https://web.archive.org/web/20200125123
                             547/https://pragprog.com/book/bkviml/the-viml-prime
                             r). Archived from[the                              
                             original](https://pragprog.com/book/bkviml/the-viml
                             -primer)on 25 January 2020.                        

                             Retrieved 25 January 2020.[^](#cite_ref-49)["Vim   
                             documentation:                                     
                             usr_41"](https://vimhelp.org/usr_41.txt.html).     
                             vimhelp.org.[Archived](https://web.archive.org/web/
                             20190113232237/https://vimhelp.org/usr_41.txt.html)
                             from the original on 13 January 2019. Retrieved 13 
                             January 2019.[^](#cite_ref-50)Verdoolaege, Sven;   
                             Gerassimof, Matt.["Vim documentation:              
                             if_perl"](http://vimdoc.sourceforge.net/htmldoc/if_
                             perl.html).[Archived](https://web.archive.org/web/2
                             0120208154924/http://vimdoc.sourceforge.net/htmldoc
                             /if_perl.html)from the original on 8 February 2012.
                             Retrieved 27 August 2019.[^](#cite_ref-51)Moore,   
                             Paul.["Vim documentation:                          
                             if_pyth"](http://vimdoc.sourceforge.net/htmldoc/if_
                             pyth.html).[Archived](https://web.archive.org/web/2
                             0120822072929/http://vimdoc.sourceforge.net/htmldoc
                             /if_pyth.html)from the original on 22 August 2012. 
                             Retrieved 27 August 2019.[^](#cite_ref-52)Carvalho,
                             Luis.["Vim documentation:                          
                             if_lua"](http://vimdoc.sourceforge.net/htmldoc/if_l
                             ua.html).[Archived](https://web.archive.org/web/201
                             20330221044/http://vimdoc.sourceforge.net/htmldoc/i
                             f_lua.html)from the original on 30 March 2012.     

                             Retrieved 27 August 2019.[^](#cite_ref-53)Maeda,   
                             Shugo.["Vim documentation:                         
                             if_ruby"](http://vimdoc.sourceforge.net/htmldoc/if_
                             ruby.html).[Archived](https://web.archive.org/web/2
                             0120214174436/http://vimdoc.sourceforge.net/htmldoc
                             /if_ruby.html)from the original on 14 February     
                             2012. Retrieved 27 August                          
                             2019.[^](#cite_ref-54)Wilken, Ingo.["Vim           
                             documentation:                                     
                             if_tcl"](http://vimdoc.sourceforge.net/htmldoc/if_t
                             cl.html).[Archived](https://web.archive.org/web/201
                             20824172051/http://vimdoc.sourceforge.net/htmldoc/i
                             f_tcl.html)from the original on 24 August 2012.    
                             Retrieved 27 August 2019.[^](#cite_ref-55)Khorev,  
                             Sergey.["Vim documentation:                        
                             if_mzsch"](http://vimdoc.sourceforge.net/htmldoc/if
                             _mzsch.html).[Archived](https://web.archive.org/web
                             /20120414232343/http://vimdoc.sourceforge.net/htmld
                             oc/if_mzsch.html)from the original on 14 April     
                             2012. Retrieved 27 August 2019.[^](#cite_ref-56)"  

                             "[:help                                            
                             sys-file-list](https://vimhelp.org/#sys-file-list)[
                             "Vim Online:                                       
                             Downloads"](http://www.vim.org/download.php).[Archi
                             ved](https://web.archive.org/web/20070108142446/htt
                             p://www.vim.org/download.php)from the original on 8
                             January 2007. Retrieved 7 January                  
                             2007.[^](#cite_ref-57)["Mac OS X Manual Page For   
                             vim(1)"](https://developer.apple.com/library/mac/#D
                             OCUMENTATION/Darwin/Reference/ManPages/man1/vim.1.h
                             tml). developer.apple.com. Apple                   
                             Inc.[Archived](https://web.archive.org/web/20120609
                             170929/http://developer.apple.com/library/mac/#DOCU
                             MENTATION/Darwin/Reference/ManPages/man1/vim.1.html
                             )from the original on 9 June 2012.                 

                             Retrieved 12 January                               
                             2010.[^](#cite_ref-58)["VimTouch, the development  
                             has stalled on this                                
                             app"](https://github.com/momodalo/vimtouch).[GitHub
                             ](/wiki/GitHub).[Archived](https://web.archive.org/
                             web/20151229012338/https://github.com/momodalo/vimt
                             ouch)from the original on 29 December 2015.        
                             Retrieved 9 August                                 
                             2015.[^](#cite_ref-59)["DroidVim, under active     
                             development"](https://github.com/shiftrot/droidvim)
                             .[GitHub](/wiki/GitHub).[Archived](https://web.arch
                             ive.org/web/20180627111225/https://github.com/shift
                             rot/droidvim)from the original on 27 June 2018.    
                             Retrieved 5 March 2017.[^](#cite_ref-60)["Vim –    
                             Applidium, mobile agency in                        
                             Paris"](https://web.archive.org/web/20120120032008/
                             http://applidium.com/en/applications/vim/).        

                             Archived from[the                                  
                             original](http://applidium.com/en/applications/vim/
                             )on 20 January 2012. Retrieved 11 August           
                             2015.[^](#cite_ref-wikidata-838a5f706459111b6a27d0d
                             54134e87800741340-v18_61-0)["Release               
                             0.10.4"](https://github.com/neovim/neovim/releases/
                             tag/v0.10.4). 29 January 2025. Retrieved 25        
                             February 2025.[^](#cite_ref-62)["Neovim: vim, out  
                             of the box"](http://neovim.io/).                   
                             neovim.io.[Archived](https://web.archive.org/web/20
                             220516140503/https://neovim.io/)from the original  
                             on 16 May 2022.                                    

                             Retrieved 2 May 2024.[^](#cite_ref-63)["Neovim     
                             Vision"](https://neovim.io/charter/).[Archived](htt
                             ps://web.archive.org/web/20220426002631/https://neo
                             vim.io/charter/)from the original on 26 April 2022.
                             Retrieved 18 February 2016.[^](#cite_ref-64)["Nvim 
                             documentation:                                     
                             vim_diff"](https://neovim.io/doc/user/vim_diff.html
                             ).[Archived](https://web.archive.org/web/2019082521
                             3838/https://neovim.io/doc/user/vim_diff.html)from 
                             the original on 25 August 2019. Retrieved 2 October
                             2019.[^](#cite_ref-66)["GitHub – neovim/neovim:    
                             Vim-fork focused on extensibility and              
                             usability"](https://github.com/neovim/neovim).[GitH
                             ub](/wiki/GitHub). 29 August                       
                             2019.[Archived](https://web.archive.org/web/2016021
                             0002828/https://github.com/neovim/neovim)from the  
                             original on 10 February 2016.                      

                             Retrieved 18 February                              
                             2016.[^](#cite_ref-67)["Switching to               
                             NeoVim"](http://arusahni.net/blog/2015/03/switching
                             -to-neovim-part-1.html). 31 March                  
                             2015.[Archived](https://web.archive.org/web/2016021
                             6025559/http://arusahni.net/blog/2015/03/switching-
                             to-neovim-part-1.html)from the original on 16      
                             February 2016. Retrieved 18 February               
                             2016.[^](#cite_ref-68)["How to start using Neovim  
                             instead of                                         
                             Vim"](http://veelenga.com/editors/how-to-start-usin
                             g-neovim-instead-of-vim/).[Archived](https://web.ar
                             chive.org/web/20170604054638/http://veelenga.com/ed
                             itors/how-to-start-using-neovim-instead-of-vim/)fro
                             m the original on 4 June 2017. Retrieved 18        
                             February 2016.[^](#cite_ref-69)Eddie Kovsky (1     
                             February 2017).["Vim's 25th anniversary and the    
                             release of Vim 8                                   
                             [LWN.net]"](https://lwn.net/Articles/713114/).     
                             lwn.net. Retrieved 13 June                         
                             2023.[^](#cite_ref-70)["Vimcasts.org blog          
                             post"](http://vimcasts.org/blog/2014/03/support-neo
                             vim/).[Archived](https://web.archive.org/web/202108
                             17071909/http://vimcasts.org/blog/2014/03/support-n
                             eovim/)from the original on 17 August 2021.        
                             Retrieved 18 February                              
                             2016.[^](#cite_ref-71)["Neovim"](https://www.bounty
                             source.com/teams/neovim/fundraiser).[Bountysource](
                             /wiki/Bountysource).                               

                             23 March                                           
                             2014.[Archived](https://web.archive.org/web/2021010
                             5163307/https://www.bountysource.com/teams/neovim/f
                             undraiser)from the original on 5 January 2021.     
                             Retrieved 20 March 2021.[^](#cite_ref-72)["NyaoVim 
                             frontend"](https://github.com/rhysd/NyaoVim).[GitHu
                             b](/wiki/GitHub). 29 August                        
                             2019.[Archived](https://web.archive.org/web/2022043
                             0094112/https://github.com/rhysd/NyaoVim)from the  
                             original on 30 April 2022. Retrieved 18 February   
                             2016.[^](#cite_ref-73)["Mac OS X                   
                             frontend"](https://github.com/rogual/neovim-dot-app
                             ).[GitHub](/wiki/GitHub). 29 August                
                             2019.[Archived](https://web.archive.org/web/2022041
                             7165446/https://github.com/rogual/neovim-dot-app)fr
                             om the original on 17 April 2022. Retrieved 18     
                             February 2016.[^](#cite_ref-74)["Neovim-Qt         
                             frontend"](https://github.com/equalsraf/neovim-qt).
                             [GitHub](/wiki/GitHub). 21 July                    
                             2020.[Archived](https://web.archive.org/web/2019091
                             6231726/https://github.com/equalsraf/neovim-qt)from
                              the original on 16 September 2019. Retrieved 17   
                             July 2019.[^](#cite_ref-75)Ayooluwa Isaiah (3      
                             August 2021).["New features in Neovim 0.5          
                             [LWN.net]"](https://lwn.net/Articles/864712/).     
                             lwn.net. Retrieved 13 June 2023.                   

                             External links                                     
                             [[edit](/w/index.php?title=Vim_(text_editor)&action
                             =edit§ion=17)]                                     
                             [Learning the vi                                   
                             Editor](https://en.wikibooks.org/wiki/Learning_the_
                             vi_Editor)has a page on the topic of:              
                             [Vim](https://en.wikibooks.org/wiki/Learning_the_vi
                             _Editor/Vim)                                       
                             [Vim](https://commons.wikimedia.org/wiki/Category:V
                             im).                                               
                             [Categories](/wiki/Help:Category):                 

                             [1991 software](/wiki/Category:1991_software)[Amiga
                             software](/wiki/Category:Amiga_software)[BeOS text 
                             editors](/wiki/Category:BeOS_text_editors)[Classic 
                             Mac OS text                                        
                             editors](/wiki/Category:Classic_Mac_OS_text_editors
                             )[Computer science in the                          
                             Netherlands](/wiki/Category:Computer_science_in_the
                             _Netherlands)[Cross-platform free                  
                             software](/wiki/Category:Cross-platform_free_softwa
                             re)[DOS text                                       
                             editors](/wiki/Category:DOS_text_editors)[Free file
                             comparison                                         
                             tools](/wiki/Category:Free_file_comparison_tools)[F
                             ree software programmed in                         
                             C](/wiki/Category:Free_software_programmed_in_C)[Fr
                             ee text                                            
                             editors](/wiki/Category:Free_text_editors)[Informat
                             ion technology in the                              
                             Netherlands](/wiki/Category:Information_technology_
                             in_the_Netherlands)[Linux text                     
                             editors](/wiki/Category:Linux_text_editors)[MacOS  
                             text                                               
                             editors](/wiki/Category:MacOS_text_editors)[MorphOS
                             software](/wiki/Category:MorphOS_software)[OpenVMS 

                             text                                               
                             editors](/wiki/Category:OpenVMS_text_editors)[OS/2 
                             text                                               
                             editors](/wiki/Category:OS/2_text_editors)[Termcap]
                             (/wiki/Category:Termcap)[Unix text                 
                             editors](/wiki/Category:Unix_text_editors)[Vi](/wik
                             i/Category:Vi)[Windows text                        
                             editors](/wiki/Category:Windows_text_editors)[Text 
                             editors that use                                   
                             GTK](/wiki/Category:Text_editors_that_use_GTK)[Free
                             HTML                                               
                             editors](/wiki/Category:Free_HTML_editors)[Linux   
                             integrated development                             
                             environments](/wiki/Category:Linux_integrated_devel
                             opment_environments)[Hex                           
                             editors](/wiki/Category:Hex_editors)[Free          
                             integrated development                             
                             environments](/wiki/Category:Free_integrated_develo
                             pment_environments)[Free integrated development    
                             environments for                                   
                             Python](/wiki/Category:Free_integrated_development_
                             environments_for_Python)[Free and open-source      
                             software](/wiki/Category:Free_and_open-source_softw
                             are)[Command-line                                  
                             software](/wiki/Category:Command-line_software)[Con
                             sole                                               
                             applications](/wiki/Category:Console_applications) 

                             Emacs                                              
                             Emacs ([/ˈiːmæks/](/wiki/Help:IPA/English)         
                             [ⓘ](/wiki/File:En-us-Emacs.oga)), originally named 
                             EMACS (an acronym for "Editor                      
                             Macros"),[[1]](#cite_note-Greenberg-1)[[2]](#cite_n
                             ote-Gnu_Emacs_FAQ-2)[[3]](#cite_note-MACSimizing_TE
                             CO-3) is a family of [text                         
                             editors](/wiki/Text_editor) that are characterized 
                             by their                                           
                             [extensibility](/wiki/Extensibility).[[4]](#cite_no
                             te-4) The manual for the most widely used          
                             variant,[[5]](#cite_note-5) [GNU                   
                             Emacs](/wiki/GNU_Emacs), describes it as "the      
                             extensible, customizable, self-documenting,        
                             real-time display editor".[[6]](#cite_note-6)      
                             Development of the first Emacs began in the        
                             mid-1970s,[[7]](#cite_note-7)[[8]](#cite_note-8)   
                             and work on GNU Emacs, directly descended from the 
                             original, is ongoing; its latest version is        
                             30.1[[9]](#cite_note-wikidata-7d4c2b2092cb944b3a0a4
                             1b985d72cb5868baa4a-v18-9) [, released February    
                             2025.                                              
                             ](https://www.wikidata.org/wiki/Q189722?uselang=en#
                             P348)                                              

                             Emacs has over 10,000 built-in commands and its    
                             [user interface](/wiki/User_interface) allows the  
                             user to combine these commands into                
                             [macros](/wiki/Macro_(computer_science)) to        
                             automate work. Implementations of Emacs typically  
                             feature a [dialect](/wiki/Dialect_(computing)) of  
                             the [Lisp](/wiki/Lisp_(programming_language))      
                             programming language, allowing users and developers
                             to write new commands and applications for the     
                             editor. Extensions have been written to, among     
                             other things, manage [files](/wiki/Dired), [remote 
                             access](/wiki/Secure_Shell),[[10]](#cite_note-10)  
                             [e-mail](/wiki/Gnus), [outlines](/wiki/Org-mode),  
                             [multimedia](/wiki/EMMS_(media_player)),           
                             [Git](/wiki/Magit) integration, [RSS](/wiki/RSS)   
                             feeds,[[11]](#cite_note-11) and [collaborative     
                             editing](/wiki/Collaborative_editing),[[12]](#cite_
                             note-12) as well as implementations of             
                             [ELIZA](/wiki/ELIZA), [Pong](/wiki/Pong), [Conway's
                             Life](/wiki/Conway%27s_Game_of_Life),              
                             [Snake](/wiki/Snake_(video_game_genre)),           
                             [Dunnet](/wiki/Dunnet_(video_game)), and           
                             [Tetris](/wiki/Tetris).[[13]](#cite_note-13)       

                             The original EMACS was written in 1976 by [David A.
                             Moon](/wiki/David_A._Moon) and [Guy L. Steele      
                             Jr.](/wiki/Guy_L._Steele_Jr.) as a set of macros   
                             for the [TECO](/wiki/TECO_(text_editor))           
                             editor.[[14]](#cite_note-jwz_timeline-14)[[1]](#cit
                             e_note-Greenberg-1)[[2]](#cite_note-Gnu_Emacs_FAQ-2
                             )[[3]](#cite_note-MACSimizing_TECO-3)[[15]](#cite_n
                             ote-15) It was inspired by the ideas of the        
                             TECO-macro editors TECMAC and                      
                             TMACS.[[16]](#cite_note-16)                        
                             The most popular, and most ported, version of Emacs
                             is GNU Emacs, which was created by [Richard        
                             Stallman](/wiki/Richard_Stallman) for the [GNU     
                             Project](/wiki/GNU_Project).[[17]](#cite_note-17)  
                             [XEmacs](/wiki/XEmacs) is a variant that           
                             [branched](/wiki/Fork_(software_development)) from 
                             GNU Emacs in 1991. GNU Emacs and XEmacs use similar
                             Lisp dialects and are, for the most part,          
                             compatible with each other. XEmacs development is  
                             inactive.                                          

                             [GNU Emacs](/wiki/GNU_Emacs) is, along with        
                             [vi](/wiki/Vi_(text_editor)), one of the two main  
                             contenders in the traditional [editor              
                             wars](/wiki/Editor_war) of [Unix](/wiki/Unix)      
                             culture. GNU Emacs is among the oldest [free and   
                             open source](/wiki/Free_and_open_source) projects  
                             still under development.[[18]](#cite_note-18)      
                             History                                            
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=1)
                             ]                                                  
                             Emacs development began during the 1970s at the    
                             [MIT AI                                            
                             Lab](/wiki/MIT_Computer_Science_and_Artificial_Inte
                             lligence_Laboratory), whose [PDP-6](/wiki/PDP-6)   
                             and [PDP-10](/wiki/PDP-10) computers used the      
                             [Incompatible Timesharing                          
                             System](/wiki/Incompatible_Timesharing_System)     
                             (ITS) [operating system](/wiki/Operating_system)   
                             that featured a default [line                      
                             editor](/wiki/Line_editor) known as [Tape Editor   
                             and Corrector](/wiki/Text_Editor_and_Corrector)    
                             (TECO). Unlike most modern text editors, TECO used 
                             separate modes in which the user would either add  
                             text, edit existing text, or display the document. 
                             One could not place characters directly into a     
                             document by typing them into TECO, but would       
                             instead enter a character ('i') in the TECO command
                             language telling it to switch to input mode, enter 
                             the required characters, during which time the     
                             edited text was not displayed on the screen, and   
                             finally enter a character (<esc>) to switch the    
                             editor back to command mode. (A similar technique  
                             was used to allow overtyping.) This behavior is    
                             similar to that of the program                     
                             [ed](/wiki/Ed_(text_editor)).                      

                             By the 1970s, TECO was already an old program,     
                             initially released in 1962. [Richard               
                             Stallman](/wiki/Richard_Stallman) visited the      
                             [Stanford AI                                       
                             Lab](/wiki/Stanford_University_centers_and_institut
                             es#Stanford_Artificial_Intelligence_Laboratory) in 
                             1976[[20]](#cite_note-20) and saw the lab's E      
                             editor, written by Fred                            
                             Wright.[[21]](#cite_note-21) He was impressed by   
                             the editor's intuitive [WYSIWYG](/wiki/WYSIWYG)    
                             (What You See Is What You Get) behavior, which has 
                             since become the default behavior of most modern   
                             text editors. He returned to MIT where Carl        
                             Mikkelsen, a                                       
                             [hacker](/wiki/Hacker_(programmer_subculture)) at  
                             the AI Lab, had added to TECO a combined           
                             display/editing mode called Control-R that allowed 
                             the screen display to be updated each time the user
                             entered a keystroke. Stallman reimplemented this   
                             mode to run efficiently and then added a           
                             [macro](/wiki/Macro_(computer_science)) feature to 
                             the TECO display-editing mode that allowed the user
                             to redefine any keystroke to run a TECO            
                             program.[[3]](#cite_note-MACSimizing_TECO-3)       

                             E had another feature that TECO lacked:            
                             random-access editing. TECO was a page-sequential  
                             editor that was designed for editing [paper        
                             tape](/wiki/Paper_tape) on the [PDP-1](/wiki/PDP-1)
                             at a time when computer memory was generally small 
                             due to cost, and it was a feature of TECO that     
                             allowed editing on only one page at a time         
                             sequentially in the order of the pages in the file.
                             Instead of adopting E's approach of structuring the
                             file for page-random access on disk, Stallman      
                             modified TECO to handle large buffers more         
                             efficiently and changed its file-management method 
                             to read, edit, and write the entire file as a      
                             single buffer. Almost all modern editors use this  
                             approach.                                          

                             The new version of TECO quickly became popular at  
                             the AI Lab and soon accumulated a large collection 
                             of custom macros whose names often ended in MAC or 
                             MACS, which stood for macro. Two years later, [Guy 
                             Steele](/wiki/Guy_L._Steele,_Jr.) took on the      
                             project of unifying the diverse macros into a      
                             single set.[[22]](#cite_note-22) Steele and        
                             Stallman's finished implementation included        
                             facilities for extending and documenting the new   
                             macro set.[[3]](#cite_note-MACSimizing_TECO-3) The 
                             resulting system was called EMACS, which stood for 
                             Editing MACroS or, alternatively, E with MACroS.   
                             Stallman picked the name Emacs "because <E> was not
                             in use as an abbreviation on ITS at the            
                             time."[[23]](#cite_note-23) An                     
                             [apocryphal](/wiki/Apocrypha) [hacker              
                             koan](/wiki/Hacker_koan#Emacs_and_Bolio) alleges   
                             that the program was named after [Emack &          
                             Bolio's](/wiki/Emack_%26_Bolio%27s), a popular     
                             [Boston](/wiki/Boston) ice cream                   
                             store.[[24]](#cite_note-24) The first operational  
                             EMACS system existed in late                       
                             1976.[[25]](#cite_note-519a-25)                    

                             Stallman saw a problem in too much customization   
                             and de facto forking and set certain conditions for
                             usage.[[citation                                   
                             needed](/wiki/Wikipedia:Citation_needed)] He later 
                             wrote:[[25]](#cite_note-519a-25)                   
                             EMACS was distributed on a basis of communal       
                             sharing, which means all improvements must be given
                             back to me to be incorporated and distributed.     
                             The original Emacs, like TECO, ran only on the     
                             PDP-10 running ITS. Its behavior was sufficiently  
                             different from that of TECO that it could be       
                             considered a text editor in its own right, and it  
                             quickly became the standard editing program on ITS.
                             Mike McMahon [ported](/wiki/Porting) Emacs from ITS
                             to the [TENEX](/wiki/TENEX_(operating_system)) and 
                             [TOPS-20](/wiki/TOPS-20) operating systems. Other  
                             contributors to early versions of Emacs include    
                             [Kent Pitman](/wiki/Kent_Pitman), [Earl            
                             Killian](/w/index.php?title=Earl_Killian_(engineer)
                             &action=edit&redlink=1), and [Eugene               
                             Ciccarelli](/w/index.php?title=Eugene_Ciccarelli&ac
                             tion=edit&redlink=1). By 1979, Emacs was the main  
                             editor used in MIT's AI lab and its Laboratory for 
                             Computer Science.[[26]](#cite_note-26)             

                             Implementations                                    
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=2)
                             ]                                                  
                             Early implementations                              
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=3)
                             ]                                                  
                             In the following years, programmers wrote a variety
                             of Emacs-like editors for other computer systems.  
                             These included [EINE](/wiki/EINE) (EINE Is Not     
                             EMACS) and [ZWEI](/wiki/ZWEI)[[27]](#cite_note-27) 
                             (ZWEI Was EINE Initially), which were written for  
                             the [Lisp machine](/wiki/Lisp_machine) by Mike     
                             McMahon and [Daniel Weinreb](/wiki/Daniel_Weinreb),
                             and Sine (Sine Is Not Eine),[[28]](#cite_note-28)  
                             which was written by Owen Theodore Anderson.       
                             Weinreb's [EINE](/wiki/EINE) was the first Emacs   
                             written in Lisp. In 1978, [Bernard                 
                             Greenberg](/wiki/Bernard_Greenberg) wrote [Multics 
                             Emacs](/wiki/Multics_Emacs) almost entirely in     
                             Multics Lisp at [Honeywell](/wiki/Honeywell)'s     
                             Cambridge Information Systems Lab. Multics Emacs   
                             was later maintained by [Richard                   
                             Soley](/wiki/Richard_Soley), who went on to develop
                             the NILE Emacs-like editor for the NIL Project, and
                             by Barry Margolin. Many versions of Emacs,         
                             including GNU Emacs, would later adopt Lisp as an  
                             extension language.                                

                             [James Gosling](/wiki/James_Gosling), who would    
                             later invent [NeWS](/wiki/NeWS) and the [Java      
                             programming                                        
                             language](/wiki/Java_(programming_language)), wrote
                             [Gosling Emacs](/wiki/Gosling_Emacs) in 1981. The  
                             first Emacs-like editor to run on                  
                             [Unix](/wiki/Unix)[[citation                       
                             needed](/wiki/Wikipedia:Citation_needed)], Gosling 
                             Emacs was written in                               
                             [C](/wiki/C_(programming_language)) and used       
                             [Mocklisp](/wiki/Mocklisp), a language with        
                             Lisp-like syntax, as an extension language.        

                             Early Ads for [Computer Corporation of             
                             America](/wiki/Computer_Corporation_of_America)'s  
                             CCA EMACS (Steve                                   
                             Zimmerman)[[29]](#cite_note-Emacs.BookCCA-29)      
                             appeared in 1984.[[30]](#cite_note-30) 1985        
                             comparisons to GNU Emacs, when it came out,        
                             mentioned free vs.                                 
                             $2,400.[[31]](#cite_note-31)[[irrelevant           
                             citation](/wiki/Wikipedia:Verifiability)]          
                             GNU Emacs                                          
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=4)
                             ]                                                  

                             Richard Stallman began work on GNU Emacs in 1984 to
                             produce a [free software](/wiki/Free_software)     
                             alternative to the proprietary Gosling Emacs. GNU  
                             Emacs was initially based on Gosling Emacs, but    
                             Stallman's replacement of its Mocklisp interpreter 
                             with a true Lisp interpreter required that nearly  
                             all of its code be rewritten. This became the first
                             program released by the nascent GNU Project. GNU   
                             Emacs is written in                                
                             [C](/wiki/C_(programming_language)) and provides   
                             [Emacs Lisp](/wiki/Emacs_Lisp), also implemented in
                             C, as an extension language. Version 13, the first 
                             public release, was made on March 20, 1985. The    
                             first widely distributed version of GNU Emacs was  
                             version 15.34, released later in 1985. Early       
                             versions of GNU Emacs were numbered as 1.x.x, with 
                             the initial digit denoting the version of the C    
                             core. The 1 was dropped after version 1.12, as it  
                             was thought that the major number would never      
                             change, and thus the numbering skipped from 1 to   
                             13.[[32]](#cite_note-32) In September 2014, it was 
                             announced on the GNU emacs-devel mailing list that 
                             GNU Emacs would adopt a [rapid                     
                             release](/w/index.php?title=Rapid_release&action=ed
                             it&redlink=1) strategy and version numbers would   
                             increment more quickly in the                      
                             future.[[33]](#cite_note-33)                       

                             GNU Emacs offered more features than Gosling Emacs,
                             in particular a full-featured Lisp as its extension
                             language, and soon replaced Gosling Emacs as the de
                             facto Unix Emacs editor. [Markus                   
                             Hess](/wiki/Markus_Hess) exploited a security flaw 
                             in GNU Emacs' email subsystem in his 1986 cracking 
                             spree in which he gained                           
                             [superuser](/wiki/Superuser) access to Unix        
                             computers.[[34]](#cite_note-34)                    
                             Most of GNU Emacs functionality is implemented     
                             through a [scripting                               
                             language](/wiki/Scripting_language) called [Emacs  
                             Lisp](/wiki/Emacs_Lisp). Because about 70% of GNU  
                             Emacs is written in the Emacs Lisp extension       
                             language,[[35]](#cite_note-35) one only needs to   
                             port the C core which implements the Emacs Lisp    
                             interpreter. This makes porting Emacs to a new     
                             platform considerably less difficult than porting  
                             an equivalent project consisting of native code    
                             only.                                              

                             GNU Emacs development was relatively closed until  
                             1999 and was used as an example of the Cathedral   
                             development style in [The Cathedral and the        
                             Bazaar](/wiki/The_Cathedral_and_the_Bazaar). The   
                             project has since adopted a public development     
                             mailing list and anonymous                         
                             [CVS](/wiki/Concurrent_Versions_System) access.    
                             Development took place in a single CVS trunk until 
                             2008 and was then switched to the Bazaar           
                             [DVCS](/wiki/Distributed_Version_Control_System).  
                             On November 11, 2014, development was moved to     
                             [Git](/wiki/Git_(software)).[[36]](#cite_note-36)  
                             Richard Stallman has remained the principal        
                             maintainer of GNU Emacs, but he has stepped back   
                             from the role at times. Stefan Monnier and Chong   
                             Yidong were maintainers from 2008 to               
                             2015.[[37]](#cite_note-37)[[38]](#cite_note-38)    
                             John Wiegley was named maintainer in 2015 after a  
                             meeting with Stallman at MIT.[[39]](#cite_note-39) 
                             As of early 2014, GNU Emacs has had 579 individual 
                             [committers](/wiki/Commit_(revision_control))      
                             throughout its history.[[40]](#cite_note-40)       
                             XEmacs                                             
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=5)
                             ]                                                  

                             Lucid Emacs, based on an early alpha version of GNU
                             Emacs 19, was developed beginning in 1991 by [Jamie
                             Zawinski](/wiki/Jamie_Zawinski) and others at      
                             [Lucid Inc.](/wiki/Lucid_Inc.) One of the          
                             best-known early forks in [free                    
                             software](/wiki/Free_software) development occurred
                             when the codebases of the two Emacs versions       
                             diverged and the separate development teams ceased 
                             efforts to merge them back into a single           
                             program.[[41]](#cite_note-41) Lucid Emacs has since
                             been renamed [XEmacs](/wiki/XEmacs). Its           
                             development is currently inactive, with the most   
                             recent stable version 21.4.22 released in January  
                             2009 (while a beta was released in 2013), while GNU
                             Emacs has implemented many formerly XEmacs-only    
                             features.[[42]](#cite_note-42)[[better source      
                             needed](/wiki/Wikipedia:NOTRS)]                    
                             Other forks of GNU Emacs                           
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=6)
                             ]                                                  
                             Other notable forks include:                       
                             - Aquamacs – based on GNU Emacs (Aquamacs 3.2 is   
                             based on GNU Emacs version 24 and Aquamacs 3.3 is  
                             based on GNU Emacs version 25) which focuses on    
                             integrating with the Apple Macintosh user interface

                             [Meadow](/wiki/Meadow_(programming))– a Japanese   
                             version for Microsoft Windows[[43]](#cite_note-43) 
                             Various Emacs editors                              
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=7)
                             ]                                                  
                             In the past, projects aimed at producing small     
                             versions of Emacs proliferated. GNU Emacs was      
                             initially targeted at computers with a 32-bit flat 
                             address space and at least 1 [MiB](/wiki/Mebibyte) 
                             of RAM.[[44]](#cite_note-44) Such computers were   
                             high end [workstations](/wiki/Workstation) and     
                             [minicomputers](/wiki/Minicomputer) in the 1980s,  
                             and this left a need for smaller reimplementations 
                             that would run on common [personal                 
                             computer](/wiki/Personal_computer) hardware.       
                             Today's computers have more than enough power and  
                             capacity to eliminate these restrictions, but small
                             clones have more recently been designed to fit on  
                             software installation disks or for use on less     
                             capable hardware.[[45]](#cite_note-45)             
                             Other projects aim to implement Emacs in a         
                             different dialect of Lisp or a different           
                             programming language altogether. Although not all  
                             are still actively maintained, these clones        
                             include:                                           

                             [MicroEMACS](/wiki/MicroEMACS), which was          
                             originally written by Dave Conroy and further      
                             developed by Daniel Lawrence and which exists in   
                             many variations.[mg](/wiki/Mg_(text_editor)),      
                             originally called MicroGNUEmacs and, later, mg2a, a
                             public-domain offshoot of MicroEMACS intended to   
                             more closely resemble GNU Emacs. Now installed by  
                             default                                            
                             on[OpenBSD](/wiki/OpenBSD).[JOVE](/wiki/JOVE)(Jonat
                             han's Own Version of Emacs), Jonathan Payne's      
                             non-programmable Emacs implementation              
                             for[UNIX-like](/wiki/UNIX-like)systems.[MINCE](/wik
                             i/MINCE)(MINCE Is Not Complete Emacs), a version   
                             for[CP/M](/wiki/CP/M)and later DOS, from[Mark of   
                             the Unicorn](/wiki/Mark_of_the_Unicorn). MINCE     
                             evolved into Final Word, which eventually became   
                             the                                                
                             Borland[Sprint](/wiki/Sprint_(word_processor))word 
                             processor.[Perfect Writer](/wiki/Perfect_Writer),  
                             a[CP/M](/wiki/CP/M)implementation derived from     
                             MINCE that was included circa 1982 as the default  
                             word processor with the very earliest releases of  
                             the Kaypro II and Kaypro IV.                       

                             It was later provided with the Kaypro 10 as an     
                             alternative                                        
                             to[WordStar](/wiki/WordStar).[Freemacs](/wiki/Freem
                             acs), a[DOS](/wiki/DOS)version that uses an        
                             extension language based on text macro expansion   
                             and fits within the original                       
                             64[KiB](/wiki/Kibibyte)flat memory                 
                             limit.[Zmacs](/wiki/Zmacs), for the MIT[Lisp       
                             Machine](/wiki/Lisp_Machine)and its descendants,   
                             implemented                                        
                             in[ZetaLisp](/wiki/ZetaLisp).[Epsilon](/wiki/Epsilo
                             n_(text_editor)),[[46]](#cite_note-46)an Emacs     
                             clone by Lugaru Software. Versions for DOS,        
                             Windows, Linux, FreeBSD, Mac OS X and OS/2 are     
                             bundled in the release. It uses a non-Lisp         
                             extension language with C syntax and used a very   
                             early concurrent command shell buffer              
                             implementation under the single-tasking            
                             MS-DOS.[PceEmacs](/wiki/PceEmacs)is the Emacs-based
                             editor                                             
                             for[SWI-Prolog](/wiki/SWI-Prolog).[Hemlock](/wiki/H
                             emlock_(text_editor)), originally written in[Spice 
                             Lisp](/wiki/Spice_Lisp), then[Common               
                             Lisp](/wiki/Common_Lisp). A part of[CMU Common     
                             Lisp](/wiki/CMU_Common_Lisp). Influenced           
                             by[Zmacs](/wiki/Zmacs). Later forked by Lucid      
                             Common Lisp (as                                    
                             Helix),[LispWorks](/wiki/LispWorks)and[Clozure     
                             CL](/wiki/Clozure_CL)projects. There is also a     
                             Portable Hemlock project, which aims to provide a  
                             Hemlock, which runs on several Common Lisp         
                             implementations.[edwin](/wiki/MIT/GNU_Scheme), an  
                             Emacs-like text editor included with MIT/GNU       
                             Scheme.                                            

                             Editors with Emacs emulation                       
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=8)
                             ]                                                  
                             - The                                              

                             [Cocoa text system](/wiki/Cocoa_text_system)uses   
                             some of the same terminology and understands many  
                             Emacs navigation bindings. This is possible because
                             the native UI uses the[Command                     
                             key](/wiki/Command_key)(equivalent to Super)       
                             instead of the[Control                             
                             key](/wiki/Control_key).[[47]](#cite_note-47)      
                             [Eclipse (IDE)](/wiki/Eclipse_(software))provides a
                             set of Emacs keybindings.[Epsilon (text            
                             editor)](/wiki/Epsilon_(text_editor))Defaults to   
                             Emacs emulation and supports a vi mode.[GNOME      
                             Builder](/wiki/GNOME_Builder)has an emulation mode 
                             for Emacs.[GNU Readline](/wiki/GNU_Readline)is     
                             a[line editor](/wiki/Line_editor)that understands  
                             the standard Emacs navigation keybindings. It also 
                             has a[vi](/wiki/Vi_(text_editor))emulation         
                             mode.[IntelliJ IDEA](/wiki/IntelliJ_IDEA)provides a
                             set of Emacs                                       
                             keybindings.[JED](/wiki/JED_(text_editor))has an   
                             emulation mode for Emacs.[Joe's Own                
                             Editor](/wiki/Joe%27s_Own_Editor)emulates Emacs    
                             keybindings when invoked as                        
                             jmacs.[MATLAB](/wiki/MATLAB)provides Emacs         
                             keybindings for its                                
                             editor.[[48]](#cite_note-48)[Multi-Edit](/wiki/Mult
                             i-Edit)provides Emacs keybindings for its          
                             editor.[KornShell](/wiki/KornShell)has an Emacs    
                             line editing mode that predates Gnu                
                             Readline.[[49]](#cite_note-49)[Visual Studio       
                             Code](/wiki/Visual_Studio_Code)has multiple        
                             extensions available to emulate Emacs              
                             keybindings.[Oracle SQL                            
                             Developer](/wiki/Oracle_SQL_Developer)can save and 
                             load alternative keyboard-shortcut layouts. One of 
                             the built-in layouts provides Emacs-like           
                             keybindings, including using different commands to 
                             achieve closer behavior.                           

                             Features                                           
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=9)
                             ]                                                  
                             Emacs is primarily a [text                         
                             editor](/wiki/Text_editor) and is designed for     
                             manipulating pieces of text, although it is capable
                             of formatting and printing documents like a [word  
                             processor](/wiki/Word_processor) by interfacing    
                             with external programs such as                     
                             [LaTeX](/wiki/LaTeX),                              
                             [Ghostscript](/wiki/Ghostscript) or a web browser. 
                             Emacs provides commands to manipulate and          
                             [differentially display](/wiki/Syntax_highlighting)
                             [semantic](/wiki/Semantic) units of text such as   
                             [words](/wiki/Word_(linguistics)),                 
                             [sentences](/wiki/Sentence_(linguistics)),         
                             [paragraphs](/wiki/Paragraph) and [source          
                             code](/wiki/Source_code) constructs such as        
                             [functions](/wiki/Function_(programming)). It also 
                             features keyboard macros for performing            
                             user-defined batches of editing commands.          

                             GNU Emacs is a real-time display editor, as its    
                             edits are displayed onscreen as they occur. This is
                             standard behavior for modern text editors but EMACS
                             was among the earliest to implement this. The      
                             alternative is having to issue a distinct command  
                             to display text, (e.g. before or after modifying   
                             it). This was common in earlier (or merely simpler)
                             line and context editors, such as                  
                             [QED](/wiki/QED_(text_editor)) (BTS, CTSS,         
                             Multics), [ed](/wiki/Ed_(text_editor)) (Unix), ED  
                             (CP/M), and [Edlin](/wiki/Edlin) (DOS).            
                             General architecture                               
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=10
                             )]                                                 

                             Almost all of the functionality in Emacs, including
                             basic editing operations such as the insertion of  
                             characters into a file, is achieved through        
                             [functions](/wiki/Function_(programming)) written  
                             in a dialect of the [Lisp programming              
                             language](/wiki/Lisp_programming_language). The    
                             dialect used in GNU Emacs is known as [Emacs       
                             Lisp](/wiki/Emacs_Lisp) (Elisp), and was developed 
                             expressly to port Emacs to [GNU](/wiki/GNU) and    
                             [Unix](/wiki/Unix). The Emacs Lisp layer sits atop 
                             a stable core of basic services and platform       
                             abstraction written in the [C programming          
                             language](/wiki/C_programming_language), which     
                             enables GNU Emacs to be ported to a wide variety of
                             operating systems and architectures without        
                             modifying the implementation semantics of the Lisp 
                             system where most of the editor lives. In this Lisp
                             environment,                                       
                             [variables](/wiki/Variable_(programming)) and      
                             [functions](/wiki/Subroutine) can be modified with 
                             no need to rebuild or restart Emacs, with even     
                             newly redefined versions of core editor features   
                             being asynchronously compiled and loaded into the  
                             live environment to replace existing definitions.  
                             Modern GNU Emacs features both                     
                             [bytecode](/wiki/Bytecode) and [native             
                             code](/wiki/Native_code) compilation for Emacs     
                             Lisp.                                              

                             All configuration is stored in variables, classes, 
                             and data structures, and changed by simply updating
                             these live. The use of a Lisp dialect in this case 
                             is a key advantage, as Lisp syntax consists of     
                             so-called [symbolic                                
                             expressions](/wiki/S-expression) (or sexprs), which
                             can act as both evaluatable code expressions and as
                             a [data serialisation format](/wiki/Serialization) 
                             akin to, but simpler and more general than, well   
                             known ones such as [XML](/wiki/XML),               
                             [JSON](/wiki/JSON), and [YAML](/wiki/YAML). In this
                             way there is little difference in practice between 
                             customising existing features and writing new ones,
                             both of which are accomplished in the same basic   
                             way. This is operatively different from most modern
                             extensible editors, for instance such as [VS       
                             Code](/wiki/Visual_Studio_Code), in which separate 
                             languages are used to implement the interface and  
                             features of the editor and to encode its           
                             user-defined configuration and options. The goal of
                             Emacs' open design is to transparently expose      
                             Emacs' internals to the Emacs user during normal   
                             use in the same way that they would be exposed to  
                             the Emacs developer working on the [git            
                             tree](/wiki/Git), and to collapse as much as       
                             possible of the distinction between using Emacs and
                             programming Emacs, while still providing a stable, 
                             practical, and responsive editing environment for  
                             novice users.                                      

                             Interactive data                                   
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=11
                             )]                                                 
                             The main text editing [data                        
                             structure](/wiki/Data_structure) is the            
                             [buffer](/wiki/Data_buffer), a memory region       
                             containing data (usually text) with associated     
                             attributes. The most important of these are:       
                             - The point: the                                   
                             [editing cursor](/wiki/Cursor_(user_interface)); - 
                             The mark: a settable location which, along with the
                             point, enables selection of                        
                             - The region: a conceptually contiguous collection 
                             of text to which editing commands will be applied; 
                             - The name and                                     
                             [inode](/wiki/Inode)of the file the buffer is      
                             visiting (if any); - The default directory, where  
                             any                                                
                             [OS](/wiki/Operating_System)-level commands will   
                             be[executed from](/wiki/Working_directory)by       
                             default; - The buffer's modes, including a major   
                             mode possibly several minor modes                  
                             - The buffer encoding, the method by which Emacs   
                             represents buffer data to the user;                
                             - and a variety of buffer local variables and Emacs
                             Lisp state.                                        

                             Modes, in particular, are an important concept in  
                             Emacs, providing a mechanism to disaggregate Emacs'
                             functionality into sets of behaviours and keybinds 
                             relevant to specific buffers' data. Major modes    
                             provide a general package of functions and commands
                             relevant to a buffer's data and the way users might
                             be interacting with it (e.g. editing source code in
                             a specific language, [editing                      
                             hex](/wiki/Hex_editor), viewing the filesystem,    
                             interacting with [git](/wiki/Git), etc.), and minor
                             modes define subsidiary collections of             
                             functionality applicable across many major modes   
                             (such as auto-save-mode                            
                             ). Minor modes can be toggled on or off both       
                             locally to each buffer as well as globally across  
                             all buffers, while major modes can only be toggled 
                             per-buffer. Any other data relevant to a buffer but
                             not bundled into a mode can be handled by simply   
                             [focussing](/wiki/Focus_(computing)) that buffer   
                             and live modifying the relevant data directly.     
                             Any interaction with the editor (like key presses  
                             or clicking a mouse button) is realized by         
                             evaluating Emacs Lisp code, typically a command,   
                             which is a function explicitly designed for        
                             interactive use. Keys can be arbitrarily redefined 
                             and commands can also be accessed by name; some    
                             commands evaluate arbitrary Emacs Lisp code        
                             provided by the user in various ways (e.g. a family
                             of eval-                                           

                             functions, operating on the buffer                 
                             , region                                           
                             , or individual expression                         
                             ). Even the simplest user inputs (such a [printable
                             characters](/wiki/ASCII#Printable_characters)) are 
                             effectuated as Emacs Lisp functions, such as the   
                             self-insert-command                                
                             , bound by default to most keyboard keys in a      
                             typical text editing buffer, which parameterises   
                             itself with the                                    
                             [locale](/wiki/Locale_(computer_software))-defined 
                             character associated with the key used to call it. 
                             For example, pressing the f key in a buffer that   
                             accepts text input evaluates the code              
                             (self-insert-command 1 ?f)                         
                             , which inserts one copy of the character constant 
                             ?f                                                 
                             at point. The 1                                    
                             , in this case, is determined by what Emacs terms  
                             the universal argument: all Emacs command code     
                             accepts a numeric value which, in its simplest     
                             usage, indicates repetition of an action, but in   
                             more complex cases (where repetition doesn't make  
                             sense) can yield other behaviours. These arguments 
                             may be supplied via command prefices, such as      
                             Control+u 7 f, or more compactly Meta+7 f, which   
                             expands to (self-insert-command 7 ?f)              

                             . When no prefix is supplied, the universal        
                             argument is 1                                      
                             : every command implicitly runs once, but may be   
                             called multiply, or in a different way, when       
                             supplied with such a prefix. Such arguments may    
                             also be non-positive where it makes sense for them 
                             to be so - it is up to the function accepting the  
                             argument to determine, according to its own        
                             semantics, what a given number means to it. One    
                             common usage is for functions to perform actions in
                             reverse simply by checking the                     
                             [sign](/wiki/Sign_(mathematics)) of the universal  
                             argument, such as a sort command which sorts in    
                             obverse by default and in reverse when called with 
                             a negative argument, using the absolute value of   
                             its argument as the sorting key (e.g. -7           
                             sorting in reverse by column index (or delimiter)  
                             7), or undo/redo, which are simply negatives of    
                             each other (traversing forward and backward through
                             a recursive history of diffs by some number of     
                             steps at a time).                                  
                             Command language                                   
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=12
                             )]                                                 

                             Because of its relatively large vocabulary of      
                             commands, Emacs features a long-established command
                             language, to concisely express the keystrokes      
                             necessary to perform an action. This command       
                             language recognises the following shift and        
                             modifier keys: Ctrl, Alt, ⇧ Shift, Meta, Super, and
                             Hyper. Not all of these may be present on an       
                             IBM-style keyboard, though they can usually be     
                             configured as desired. These are represented in    
                             command language as the respective prefices: C-    
                             , A-                                               
                             , S-                                               
                             , M-                                               
                             , s-                                               
                             , and H-                                           
                             . Keys whose names are only printable with more    
                             than one character are enclosed in angle brackets. 
                             Thus, a keyboard shortcut such as Ctrl+Alt+⇧       
                             Shift+F9 (check dependent formulas and calculate   
                             all cells in all open workbooks in                 
                             [Excel](/wiki/Microsoft_Excel)) would be rendered  
                             in Emacs command language as C-A-S-<f9>            
                             , while an Emacs command like Meta+s f Ctrl+Meta+s 
                             (incremental file search by filename-matching      
                             [regexp](/wiki/Regular_expression)), would be      
                             expressed as M-s f C-M-s                           
                             . Command language is also used to express the     
                             actions needed to invoke commands with no assigned 
                             shortcut: for example, the command scratch-buffer  

                             (which initialises a buffer in memory for temporary
                             text storage and manipulation), when invoked by the
                             user, will be reported back as M-x scra <return>   
                             , with Emacs scanning the namespace of contextually
                             available commands to return the shortest sequence 
                             of keystrokes which uniquely lexicate it.          
                             Dynamic display                                    
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=13
                             )]                                                 
                             Because Emacs predates modern standard terminology 
                             for [graphical user                                
                             interfaces](/wiki/Graphical_user_interface), it    
                             uses somewhat divergent names for familiar         
                             interface elements. Buffers, the data that Emacs   
                             users interact with, are displayed to the user     
                             inside windows, which are [tiled                   
                             portions](/wiki/Split_screen_(computing)) of the   
                             terminal screen or the GUI window, which Emacs     
                             refers to as frames; in modern terminology, an     
                             Emacs frame would be a window and an Emacs window  
                             would be a split. Depending on configuration,      
                             windows can include their own scroll bars, line    
                             numbers, sometimes a 'header line' typically to    
                             ease navigation, and a mode line at the bottom     
                             (usually displaying buffer name, the active modes  
                             and point position of the buffer among others). The
                             bottom of every frame is used for output messages  
                             (then called 'echo area') and text input for       
                             commands (then called 'minibuffer').               

                             In general, Emacs display elements (windows,       
                             frames, etc.) do not belong to any specific data or
                             process. Buffers are not associated with windows,  
                             and multiple windows can be opened onto the same   
                             buffer, for example to track different parts of a  
                             long text side-by-side without scrolling back and  
                             forth, and multiple buffers can share the same     
                             text, for example to take advantage of different   
                             major modes in a mixed-language file. Similarly,   
                             Emacs instances are not associated with particular 
                             frames, and multiple frames can be opened          
                             displaying a single running Emacs process, e.g. a  
                             frame per screen in a multi-monitor setup, or a    
                             terminal frame connected via [ssh](/wiki/SSH) from 
                             a remote system and a graphical frame displaying   
                             the same Emacs process via the local system's      
                             monitor.                                           

                             Just as buffers don't require windows, running     
                             Emacs processes do not require any frames, and one 
                             common usage pattern is to deploy Emacs as an      
                             editing server: running it as a                    
                             [headless](/wiki/Headless_software)                
                             [daemon](/wiki/Daemon_(computing)) and connecting  
                             to it via a frame-spawning client. This server can 
                             then be made available in any situation where an   
                             editor is required, simply by declaring the client 
                             program to be the user's EDITOR                    
                             or VISUAL                                          
                             variable. Such a server continues to run in the    
                             background, managing any child processes,          
                             accumulating                                       
                             [stdin](/wiki/Standard_streams#Standard_input_(stdi
                             n)) from open pipes, ports, or fifos, performing   
                             periodic or pre-programmed actions, and remembering
                             buffer undo history, saved text snippets, command  
                             history, and other user state between editing      
                             sessions. In this mode of operation, Emacs overlaps
                             the functionality of programs like                 
                             [screen](/wiki/GNU_Screen) and [tmux](/wiki/Tmux). 

                             Because of its separation of display concerns from 
                             editing functionality, Emacs can display roughly   
                             similarly on any device more complex than a [dumb  
                             terminal](/wiki/Dumb_terminal), including providing
                             typical graphical [WIMP](/wiki/WIMP_(computing))   
                             elements on sufficiently featureful text terminals 
                             - though graphical frames are the preferred mode of
                             display, providing a strict superset of the        
                             features of text terminal frames.                  
                             Customizability and extensibility                  
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=14
                             )]                                                 
                             - User actions can be recorded into macros and     
                             replayed to automate complex, repetitive tasks.    
                             This is often done on an ad-hoc basis, with each   
                             macro discarded after use, although macros can be  
                             saved and invoked later.                           
                             - Because of the uniformity of Emacs' features'    
                             definition in terms of Emacs Lisp, what counts as a
                             "user action" for the purposes of macro-automation 
                             is flexible: macros may include, e.g., keypresses, 
                             commands, mouse clicks, other macros, and anything 
                             that can be effectuated via these. Macros can thus 
                             be recursive, and can be defined and invoked inside
                             of macros.                                         
                             - At startup, Emacs executes an Emacs Lisp script  
                             named ~/.emacs (recent versions also look for      
                             ~/emacs.el, ~/.emacs.d/init.el, and                
                             ~/.config/emacs/init.el,                           

                             [[50]](#cite_note-50)as well as similar variations 
                             on                                                 
                             ~/.config/emacs/early-init.el.[[51]](#cite_note-51)
                             Emacs reads early-init.el first if it exists, and  
                             it can be used to configure or short-circuit core  
                             Emacs features before they load, such as the       
                             graphical display system or[package                
                             manager](/wiki/Package_manager). It will then      
                             execute the first version .emacs or init.el that it
                             finds, ignoring the rest. This personal            
                             customization file can be arbitrarily long and     
                             complex, but typical content includes:- Setting    
                             global variables or invoking functions to customize
                             Emacs behaviour, for example                       
                             (set-default-coding-systems 'utf-8)                
                             [Key bindings](/wiki/Keyboard_shortcut)to override 
                             standard ones and to add shortcuts for commands    
                             that the user finds convenient but don't have a key
                             binding by default. Example:(global-set-key (kbd   
                             "C-x C-b") 'ibuffer)                               
                             - Loading, enabling and initializing extensions    
                             (Emacs comes with many extensions, but only a few  
                             are loaded by default.)                            
                             - Configuring event hooks to run arbitrary code at 
                             specific times, for example to automatically       
                             recompile source code after saving a buffer (      
                             after-save-hook                                    

                             ) - Executing arbitrary files, usually to split an 
                             overly long configuration file into manageable and 
                             homogeneous parts (~/.emacs.d/ and ~/elisp/ are    
                             traditional locations for these personal scripts)  
                             - Setting global variables or invoking functions to
                             customize Emacs behaviour, for example             
                             - The customize extension allows the user to set   
                             configuration properties such as the color scheme  
                             interactively, from within Emacs, in a more        
                             user-friendly way than by setting variables in     
                             .emacs: it offers search, descriptions and help    
                             text, multiple choice inputs, reverting to         
                             defaults, modification of the running Emacs        
                             instance without reloading, and other conveniences 
                             similar to the                                     
                             [preferences](/wiki/Preferences)functionality of   
                             other programs. The customized values are saved in 
                             .emacs (or another designated file) automatically. 
                             - Themes, affecting the choice of fonts and        
                             colours, are defined as Emacs Lisp files and chosen
                             through the customize extension.                   
                             - Modes, which support editing a range of          
                             programming languages (e.g., emacs-lisp-mode,      
                             c-mode, java-mode, ESS for R) by changing fonts to 
                             highlight the code and keybindings modified        
                             (foreword-function vs. forward-page). Other modes  
                             include ones that support editing spreadsheets     
                             (dismal) and structured text.                      

                             Self-documenting                                   
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=15
                             )]                                                 
                             The first Emacs contained a help library that      
                             included documentation for every command, variable 
                             and internal function. Because of this, Emacs      
                             proponents described the software as               
                             self-documenting in that it presents the user with 
                             information on its normal features and its current 
                             state. Each function includes a documentation      
                             string that is displayed to the user on request, a 
                             practice that subsequently spread to programming   
                             languages including                                
                             [Lisp](/wiki/Lisp_programming_language),           
                             [Java](/wiki/Java_(programming_language)),         
                             [Perl](/wiki/Perl), and                            
                             [Python](/wiki/Python_(programming_language)). This
                             help system can take users to the actual code for  
                             each function, whether from a built-in library or  
                             an added third-party library.                      
                             Emacs also has a built-in                          
                             [tutorial](/wiki/Tutorial). Emacs displays         
                             instructions for performing simple editing commands
                             and invoking the tutorial when it is launched with 
                             no file to edit. The tutorial is by Stuart Cracraft
                             and Richard Stallman.                              
                             Culture                                            
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=16
                             )]                                                 
                             Church of Emacs                                    

                             [[edit](/w/index.php?title=Emacs&action=edit§ion=17
                             )]                                                 
                             The Church of Emacs, formed by [Richard            
                             Stallman](/wiki/Richard_Stallman), is a [parody    
                             religion](/wiki/Parody_religion) created for Emacs 
                             users.[[52]](#cite_note-52) While it refers to     
                             [vi](/wiki/Vi_(text_editor)) as the editor of the  
                             beast (vi-vi-vi being [6-6-6](/wiki/666_(number))  
                             in Roman numerals), it does not oppose the use of  
                             vi; rather, it calls it [proprietary               
                             software](/wiki/Proprietary_software)              
                             [anathema](/wiki/Anathema). ("Using a              
                             [free](/wiki/Free_software) version of vi is not a 
                             sin but a                                          
                             [penance](/wiki/Penance)."[[53]](#cite_note-53))   
                             The Church of Emacs has its own                    
                             [newsgroup](/wiki/Newsgroup),                      
                             alt.religion.emacs,[[54]](#cite_note-54) that has  
                             posts purporting to support this parody religion.  
                             Supporters of vi have created an opposing Cult of  
                             vi.                                                

                             Stallman has jokingly referred to himself as St I  
                             [GNU](/wiki/GNU) cius, a saint in the Church of    
                             Emacs.[[55]](#cite_note-55) This is in reference to
                             [Ignatius of Antioch](/wiki/Ignatius_of_Antioch),  
                             an early Church father venerated in Christianity.  
                             Terminology                                        
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=18
                             )]                                                 
                             The word emacs is sometimes pluralized as emacsen, 
                             by phonetic analogy with                           
                             [boxen](https://en.wiktionary.org/wiki/boxen) and  
                             [VAXen](/wiki/VAX), referring to different         
                             varieties of Emacs.[[56]](#cite_note-56)           
                             See also                                           
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=19
                             )]                                                 
                             [Comparison of text                                
                             editors](/wiki/Comparison_of_text_editors)[Conkeror
                             ](/wiki/Conkeror)[GNU                              
                             TeXmacs](/wiki/GNU_TeXmacs)[List of text           
                             editors](/wiki/List_of_text_editors)[List of Unix  
                             commands](/wiki/List_of_Unix_commands)[Integrated  
                             development                                        
                             environment](/wiki/Integrated_development_environme
                             nt)                                                
                             References                                         
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=20
                             )]                                                 
                             - ^                                                
                             [a](#cite_ref-Greenberg_1-0)[b](#cite_ref-Greenberg
                             _1-1)Greenberg, Bernard S. (1979).[Multics Emacs:  
                             The History, Design and                            
                             Implementation](http://www.multicians.org/mepap.htm
                             l). - ^                                            

                             [a](#cite_ref-Gnu_Emacs_FAQ_2-0)[b](#cite_ref-Gnu_E
                             macs_FAQ_2-1)[c](#cite_ref-Gnu_Emacs_FAQ_2-2)["GNU 
                             Emacs                                              
                             FAQ"](https://www.gnu.org/software/emacs/emacs-faq.
                             html#Origin-of-the-term-Emacs). - ^                
                             [a](#cite_ref-MACSimizing_TECO_3-0)[b](#cite_ref-MA
                             CSimizing_TECO_3-1)[c](#cite_ref-MACSimizing_TECO_3
                             -2)[d](#cite_ref-MACSimizing_TECO_3-3)Adrienne G.  
                             Thompson.["MACSimizing                             
                             TECO"](https://web.archive.org/web/20131024150047/h
                             ttp://www.codeartnow.com/hacker-art-1/macsimizing-t
                             eco). Archived from[the                            
                             original](http://www.codeartnow.com/hacker-art-1/ma
                             csimizing-teco)on 2013-10-24. Retrieved 2012-02-26.
                             [^](#cite_ref-4)["A Tutorial Introduction to GNU   
                             Emacs"](http://www2.lib.uchicago.edu/keith/tcl-cour
                             se/emacs-tutorial.html).For an editor to be called 
                             "emacs" the main requirement is that it be fully   
                             extensible with a real programming language, not   
                             just a macro language.                             

                             [^](#cite_ref-5)["GNU Emacs Pocket                 
                             Reference"](https://ebooks-it.org/1565924967-ebook.
                             htm).GNU Emacs is the most popular and widespread  
                             of the Emacs family of editors.                    

                             [^](#cite_ref-6)["GNU Emacs                        
                             Manual"](https://www.gnu.org/software/emacs/manual/
                             html_node/emacs/index.html). FSF. Retrieved 24     
                             November 2012.[^](#cite_ref-7)Zawinski, Jamie      
                             (2007-10-29).["Emacs                               
                             Timeline"](https://www.jwz.org/doc/emacs-timeline.h
                             tml). www.jwz.org. Retrieved                       
                             2023-07-31.[^](#cite_ref-8)["On the Origin of Emacs
                             in 1976 (Emacs blog                                
                             articles)"](https://onlisp.co.uk/On-the-Origin-of-E
                             macs-in-1976.html). onlisp.co.uk. Retrieved        
                             2024-07-24.[^](#cite_ref-wikidata-7d4c2b2092cb944b3
                             a0a41b985d72cb5868baa4a-v18_9-0)["Emacs 30.1       
                             released"](https://lists.gnu.org/archive/html/emacs
                             -devel/2025-02/msg00997.html).[^](#cite_ref-10)["Tr
                             amp User                                           
                             Manual"](https://www.gnu.org/software/tramp/).[Free
                             Software                                           
                             Foundation](/wiki/Free_Software_Foundation).       
                             Retrieved 2009-04-04.[^](#cite_ref-11)["Introducing
                             Elfeed, an Emacs Web Feed                          
                             Reader"](http://nullprogram.com/blog/2013/09/04/).[
                             ^](#cite_ref-12)["Collaborative editing using      
                             Conflict-free Replicated Data                      
                             Types"](https://code.librehq.com/qhong/crdt.el).[^]
                             (#cite_ref-13)["Amusements"](https://www.gnu.org/so
                             ftware/emacs/manual/html_node/emacs/Amusements.html
                             ).Finally, if you find yourself frustrated, try    
                             describing your problems to the famous             
                             psychotherapist Eliza. Just do M-x doctor.         

                             [^](#cite_ref-jwz_timeline_14-0)[Zawinski,         
                             Jamie](/wiki/Jamie_Zawinski)(2005-06-21)           
                             [1999].["Emacs                                     
                             Timeline"](https://www.jwz.org/doc/emacs-timeline.h
                             tml). Retrieved 11 August                          
                             2015.[^](#cite_ref-15)[Richard                     
                             Stallman](/wiki/Richard_Stallman)is often credited 
                             as another co-creator, but as[Daniel               
                             Weinreb](/wiki/Daniel_Weinreb)wrote, "The original 
                             (TECO-based) Emacs was created and designed by Guy 
                             L. Steele Jr. and David Moon. After they had it    
                             working, and it had become established as the      
                             standard text editor at the AI lab, Stallman took  
                             over its maintenance." Moon himself responded "All 
                             true, so far as I can remember.                    

                             But in all fairness I have to say that Stallman    
                             greatly improved Emacs after he “liberated” it from
                             Guy and me." See[Weinreb,                          
                             Dan](/wiki/Daniel_Weinreb)(November 11,            
                             2007),["Rebuttal to Stallman's Story About The     
                             Formation of Symbolics and                         
                             LMI"](https://web.archive.org/web/20090101103828/ht
                             tp://danweinreb.org/blog/rebuttal-to-stallmans-stor
                             y-about-the-formation-of-symbolics-and-lmi), Dan   
                             Weinreb's blog: software and innovation, archived  
                             from the original on January 1,                    
                             2009.[^](#cite_ref-16)["A history of               
                             Emacs"](http://www.xemacs.org/Documentation/21.5/ht
                             ml/internals_3.html). XEmacs Internals Manual.     
                             2006-12-11. Retrieved                              
                             2007-08-22.[^](#cite_ref-17)Allombert,             
                             Bill.["Debian Popularity                           
                             Contest"](http://popcon.debian.org/main/editors/by_
                             vote). Editors report. Debian.                     

                             Retrieved 22 November 2011.[^](#cite_ref-18)["The  
                             10 oldest, significant open-source                 
                             programs"](https://www.zdnet.com/article/the-10-old
                             est-significant-open-source-programs/).[ZDNet](/wik
                             i/ZDNet).[^](#cite_ref-isbn1-56592-152-6_19-0)Raymo
                             nd, Eric S.; Cameron, Debra; Rosenblatt, Bill      
                             (1996).[Learning GNU Emacs, 2nd                    
                             Edition](https://books.google.com/books?id=a_lea3-w
                             -1kC&q=bucky+keyboard&pg=PA408). Sebastopol, CA:   
                             O'Reilly. pp.                                      
                             408–409.[ISBN](/wiki/ISBN_(identifier))[1-56592-152
                             -6](/wiki/Special:BookSources/1-56592-152-6).[^](#c
                             ite_ref-20)[Williams,                              
                             Sam](/wiki/Sam_Williams_(journalist))(2002).[Free  
                             as in Freedom: Richard Stallman's Crusade for Free 
                             Software](https://books.google.com/books?id=ou2fOwh
                             qAD8C&pg=PA82).                                    

                             Sebastopol, CA: O'Reilly Media. p.                 
                             82.[ISBN](/wiki/ISBN_(identifier))[0-596-00287-4](/
                             wiki/Special:BookSources/0-596-00287-4).[^](#cite_r
                             ef-21)Arthur Samuel (March 1980).["Essential       
                             E"](http://i.stanford.edu/pub/cstr/reports/cs/tr/80
                             /796/CS-TR-80-796.pdf)(PDF). Retrieved             
                             2020-04-19.[^](#cite_ref-22)["EMACS vs. vi: The    
                             endless geek 'holy                                 
                             war'"](https://web.archive.org/web/20141126181620/h
                             ttp://archive09.linux.com/feature/19661). Archived 
                             from[the                                           
                             original](http://archive09.linux.com/feature/19661)
                             on 2014-11-26. Retrieved 2014-05-30."EMACS as such 
                             actually started out as a standards project,"      
                             emails Guy Steele                                  

                             [^](#cite_ref-23)[Stallman, Richard                
                             M.](/wiki/Richard_Stallman)(1987).["The EMACS      
                             Full-Screen                                        
                             Editor"](http://www.lysator.liu.se/history/garb/txt
                             /87-1-emacs.txt). GARB. No. Maj 1987. Lysator,     
                             Linköping University. pp. 8–11. Retrieved          
                             2007-09-14.[^](#cite_ref-24)Reynolds, Craig        
                             (1992-02-10). Wiseman, David G. (ed.).["The Emac   
                             Bolio Name                                         
                             Koan"](https://web.archive.org/web/20030116151636/h
                             ttp://www.csd.uwo.ca/staff/magi/personal/humour/Com
                             puter_Folklore/The%20Emac%20Bolio%20Name%20Koan.htm
                             l). David G. Wiseman: Stories of Computer Folklore.
                             Archived from[the                                  
                             original](http://www.csd.uwo.ca/staff/magi/personal
                             /humour/Computer_Folklore/The%20Emac%20Bolio%20Name
                             %20Koan.html)on January 16, 2003.A cocky novice    
                             once said to Stallman: 'I can guess why the editor 
                             is called Emacs, but why is the justifier called   
                             Bolio?'. Stallman replied forcefully, Names are but
                             names, Emack & Bolio's is the name of a popular ice
                             cream shop in Boston town. Neither of these men had
                             anything to do with the software.' His question    
                             answered, yet unanswered, the novice turned to go, 
                             but Stallman called to him, 'Neither Emacs nor     
                             Bolio had anything to do with the ice cream shop,  
                             either.'                                           
                             - ^                                                

                             [a](#cite_ref-519a_25-0)[b](#cite_ref-519a_25-1)Sta
                             llman, Richard (March 26, 1981).[EMACS: The        
                             Extensible, Customizable, Self-Documenting, Display
                             Editor](http://dspace.mit.edu/bitstream/handle/1721
                             .1/5736/AIM-519A.pdf)(PDF) (Technical report). MIT 
                             AI Lab. AI Memo 519a. Retrieved 2011-01-07.        
                             [^](#cite_ref-26)Leigh Klotz (2007-08-29).["email  
                             quoted in "Be Careful What You Joke                
                             About""](http://pogue.blogs.nytimes.com/2007/08/29/
                             be-careful-what-you-joke-about/). The New York     
                             Times. Retrieved                                   
                             2010-05-01.[^](#cite_ref-27)["Comment by ZWEI's    
                             author Dan                                         
                             Weinreb"](http://steve-yegge.blogspot.be/2008/04/xe
                             macs-is-dead-long-live-xemacs.html#c818782918560086
                             0534).I wrote the second Emacs ever: the Lisp      
                             machine implementation, whose spec was "do what    
                             Stallman's PDP-10 (original) Emacs does", and then 
                             progressed from there. There's just a whole LOT of 
                             it. It took me and Mike McMahon endless hours to   
                             implement so many commands to make ZWEI/Zmacs.     

                             [^](#cite_ref-28)Owen Theodore Anderson (January   
                             1979).["The Design and Implementation of a         
                             Display-Oriented Editor Writing                    
                             System"](http://dspace.mit.edu/bitstream/handle/172
                             1.1/16038/07332831.pdf?sequence=1)(PDF). Retrieved 
                             2012-09-09.[^](#cite_ref-Emacs.BookCCA_29-0)Christo
                             pher Kelty; Mario Biagioli; Peter Jaszi; Martha    
                             Woodmansee (2015). Making and Unmaking Intellectual
                             Property.Computer Corporation of America (CCA)     
                             EMACS, written by Steve Zimmerman                  
                             [^](#cite_ref-30)["Emacs"](http://www.softwareprese
                             rvation.org/projects/emacs). December 17,          
                             2017.[^](#cite_ref-31)["Differences between GNU    
                             Emacs and CCA                                      
                             Emacs"](http://www.retro11.de/ouxr/43bsd/usr/src/ne
                             w/emacs/etc/CCADIFF).[^](#cite_ref-32)["A History  
                             of                                                 
                             Emacs"](http://www.xemacs.org/Documentation/21.5/ht
                             ml/internals_3.html).[^](#cite_ref-33)["emacs-devel
                              msg 00872                                         
                             (2014-09-29)"](http://lists.gnu.org/archive/html/em
                             acs-devel/2014-09/msg00872.html).In retrospect 24.3
                             should have been named 25.1 and 24.4 should have   
                             been named 26.1. The .N thingy should really be    
                             kept only for bug-fix releases and neither of 24.3,
                             24.4, nor the previously planned 24.5 are bug-fix  
                             releases.                                          

                             [^](#cite_ref-34)[Stoll,                           
                             Clifford](/wiki/Clifford_Stoll)(1988).["Stalking   
                             the wily                                           
                             hacker"](https://doi.org/10.1145%2F42411.42412).[Co
                             mmunications of the                                
                             ACM](/wiki/Communications_of_the_ACM). 31 (5):     
                             484–497.[doi](/wiki/Doi_(identifier)):[10.1145/4241
                             1.42412](https://doi.org/10.1145%2F42411.42412).[S2
                             CID](/wiki/S2CID_(identifier))[6956966](https://api
                             .semanticscholar.org/CorpusID:6956966).[^](#cite_re
                             f-35)["GNU                                         
                             Emacs"](https://www.openhub.net/p/emacs/analyses/la
                             test/languages_summary).[Open Hub](/wiki/Open_Hub).
                             Retrieved 2017-11-25.[^](#cite_ref-36)[Raymond,    
                             Eric](/wiki/Eric_S._Raymond)(2014-11-12).["New Git 
                             repository is                                      
                             up"](http://lists.gnu.org/archive/html/emacs-devel/
                             2014-11/msg00681.html). Retrieved                  
                             2017-11-25.[^](#cite_ref-37)[Stallman,             
                             Richard](/wiki/Richard_Stallman)(2008-02-22).["Re: 
                             Looking for a new Emacs maintainer or              
                             team"](http://lists.gnu.org/archive/html/emacs-deve
                             l/2008-02/msg02140.html).                          

                             gnu.org Mailing List. Retrieved                    
                             2017-11-25.[^](#cite_ref-38)McNamara, Paul         
                             (2008-02-25).["Stallman on handing over GNU Emacs, 
                             its future and the importance of                   
                             nomenclature"](https://web.archive.org/web/20080523
                             201156/http://www.networkworld.com/community/node/2
                             5360).[Network World](/wiki/Network_World).        
                             Archived from[the                                  
                             original](http://www.networkworld.com/community/nod
                             e/25360)on 2008-05-23. Retrieved                   
                             2017-11-25.[^](#cite_ref-39)Chirgwin, Richard      
                             (2015-11-05).["Emacs gets new maintainer as Richard
                             Stallman signs                                     
                             off"](https://www.theregister.co.uk/2015/11/05/wieg
                             ley_new_emacs_maintainer/).[The                    
                             Register](/wiki/The_Register). Retrieved           
                             2017-11-25.[^](#cite_ref-40)[Raymond,              
                             Eric](/wiki/Eric_S._Raymond)(2014-03-29).["Ugliest…
                             repository…conversion…ever"](http://esr.ibiblio.org
                             /?p=5634). Retrieved 2017-11-25.twenty-nine years  
                             of continuous development by no fewer than 579     
                             people                                             

                             [^](#cite_ref-41)Stephen J., Turnbull.["XEmacs vs. 
                             GNU                                                
                             Emacs"](http://www.xemacs.org/About/XEmacsVsGNUemac
                             s.html). Retrieved                                 
                             2012-10-02.[^](#cite_ref-42)["XEmacs is Dead. Long 
                             Live                                               
                             XEmacs!"](http://steve-yegge.blogspot.com/2008/04/x
                             emacs-is-dead-long-live-xemacs.html).[^](#cite_ref-
                             43)[FrontPage - Meadow                             
                             Wiki](http://www.meadowy.org/meadow/pukiwiki-en/)[A
                             rchived](https://web.archive.org/web/20120216081734
                             /http://www.meadowy.org/meadow/pukiwiki-en/)2012-02
                             -16 at the[Wayback                                 
                             Machine](/wiki/Wayback_Machine)[^](#cite_ref-44)["M
                             y Lisp Experiences and the Development of GNU      
                             Emacs"](https://www.gnu.org/gnu/rms-lisp.html).Ther
                             e were people in those days, in 1985, who had      
                             one-megabyte machines without virtual memory. They 
                             wanted to be able to use GNU Emacs. This meant I   
                             had to keep the program as small as possible.      

                             [^](#cite_ref-45)["GNU Zile (Zile is Lossy Emacs) -
                             Summary"](https://savannah.gnu.org/projects/zile/).
                             Modern computers have more than enough resources to
                             start and run a full Emacs in a fraction of a      
                             second, and Emacs is probably what you want. Zile  
                             is a small, fast, and powerful Emacs clone. It is  
                             useful for small footprint installations (e.g. on  
                             floppy disk), machines with little memory, or quick
                             editing sessions, especially on remote machines or 
                             as a different user, e.g. root.                    

                             [^](#cite_ref-46)["Lugaru Software                 
                             Homepage"](http://www.lugaru.com/).[^](#cite_ref-47
                             )["Cocoa text                                      
                             system"](https://www.hcs.harvard.edu/~jrus/site/coc
                             oa-text.html).[^](#cite_ref-48)["Setting up        
                             keybindings for the Command Window and             
                             Editor"](https://blogs.mathworks.com/community/2007
                             /05/11/setting-up-keybindings-for-the-command-windo
                             w-and-editor/). Mathworks Blogs. 2007-05-11.       
                             Retrieved 2019-08-18.[^](#cite_ref-49)Bolsky,      
                             Morris I.; Korn, David G. (1989).                  
                             "Acknowledgements".[The KornShell Command and      
                             Programming                                        
                             Language](https://archive.org/details/kornshellcomm
                             and00bols). Englewood Cliffs, NJ: Prentice Hall.   
                             pp.                                                
                             xii.[ISBN](/wiki/ISBN_(identifier))[0-13-516972-0](
                             /wiki/Special:BookSources/0-13-516972-0).[^](#cite_
                             ref-50)["Init                                      
                             file"](https://www.gnu.org/software/emacs/manual/ht
                             ml_node/emacs/Init-File.html).[^](#cite_ref-51)["Ea
                             rly Init                                           
                             file"](https://www.gnu.org/software/emacs/manual/ht
                             ml_node/emacs/Early-Init-File.html).[^](#cite_ref-5
                             2)["Saint IGNUcius - Richard                       
                             Stallman"](http://stallman.org/saint.html).        

                             Retrieved 29 January 2015.[^](#cite_ref-53)["The   
                             unabridged selective transcript of Richard M       
                             Stallman's talk at the                             
                             ANU"](https://web.archive.org/web/20111004151936/ht
                             tp://linuxhelp.blogspot.com/2006/04/unabridged-sele
                             ctive-transcript-of.html). Archived from[the       
                             original](http://linuxhelp.blogspot.com/2006/04/una
                             bridged-selective-transcript-of.html)on 4 October  
                             2011. Retrieved 29 January                         
                             2015.[^](#cite_ref-54)[alt.religion.emacs          
                             newsgroup](news:alt.religion.emacs)[^](#cite_ref-55
                             )["Saint IGNUcius - Richard                        
                             Stallman"](http://www.stallman.org/saint.html).    
                             www.stallman.org. Retrieved 27 March               
                             2018.[^](#cite_ref-56)["VAXen"](http://www.catb.org
                             /~esr/jargon/html/V/VAXen.html). Catb.org.         
                             Retrieved 2009-11-08.                              

                             Bibliography                                       
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=21
                             )]                                                 

                             [Ciccarelli,                                       
                             Eugene](/w/index.php?title=Eugene_Ciccarelli&action
                             =edit&redlink=1)(1978). An Introduction to the     
                             Emacs Editor. Cambridge, Massachusetts: MIT        
                             Artificial Intelligence Laboratory.                
                             AIM-447.[PDF](https://archive.org/details/bitsavers
                             _mitaiaimAI_4967481)[Stallman, Richard             
                             M.](/wiki/Richard_Stallman)(1981) [1979]. EMACS:   
                             The Extensible, Customizable, Self-Documenting     
                             Display Editor. Cambridge Massachusetts: MIT       
                             Artificial Intelligence Laboratory.                
                             AIM-519A.[PDF](https://archive.org/details/bitsaver
                             s_mitaiaimAI_2207521)[HTML](https://www.gnu.org/sof
                             tware/emacs/emacs-paper.html)[Stallman, Richard    
                             M.](/wiki/Richard_Stallman)(2002).[GNU Emacs       
                             Manual](https://www.gnu.org/software/emacs/manual/)
                             (15th ed.). GNU                                    
                             Press.[ISBN](/wiki/ISBN_(identifier))[1-882114-85-X
                             ](/wiki/Special:BookSources/1-882114-85-X).[Stallma
                             n, Richard M.](/wiki/Richard_Stallman)(2002).["My  
                             Lisp Experiences and the Development of GNU        
                             Emacs"](https://www.gnu.org/gnu/rms-lisp.html).    
                             Retrieved 2007-02-01.[Chassel, Robert              
                             J.](/wiki/Robert_J._Chassell)(2004).[An            
                             Introduction to Programming in Emacs               
                             Lisp](https://www.gnu.org/software/emacs/emacs-lisp
                             -intro/). GNU                                      
                             Press.[ISBN](/wiki/ISBN_(identifier))[1-882114-56-6
                             ](/wiki/Special:BookSources/1-882114-56-6).-       
                             Glickstein, Bob (April 1997).                      

                             [Writing GNU Emacs                                 
                             Extensions](https://archive.org/details/writinggnue
                             macse00glic). O'Reilly &                           
                             Associates.[ISBN](/wiki/ISBN_(identifier))[1-56592-
                             261-1](/wiki/Special:BookSources/1-56592-261-1). - 
                             Cameron, Debra; Elliott, James; Loy, Marc; Raymond,
                             Eric; Rosenblatt, Bill (December 2004).            

                             [Learning GNU Emacs, 3rd                           
                             Edition](http://www.oreilly.com/catalog/gnu3/).    
                             O'Reilly &                                         
                             Associates.[ISBN](/wiki/ISBN_(identifier))[0-596-00
                             648-9](/wiki/Special:BookSources/0-596-00648-9). - 
                             Finseth, Craig A. (1991).                          
                             [The Craft of Text Editing -or- Emacs for the      
                             Modern World](http://www.finseth.com/craft/).      
                             Springer-Verlag &                                  
                             Co.[ISBN](/wiki/ISBN_(identifier))[978-1-4116-8297-
                             9](/wiki/Special:BookSources/978-1-4116-8297-9). - 
                             Thompson, Adrienne G. (2009).                      
                             ["MACSimizing                                      
                             TECO"](http://www.codeartnow.com/hacker-art/macsimi
                             zing-teco). Retrieved 2012-02-26.                  
                             External links                                     
                             [[edit](/w/index.php?title=Emacs&action=edit§ion=22
                             )]                                                 
                             [Emacs](https://en.wikiquote.org/wiki/Special:Searc
                             h/Emacs).                                          
                             [Emacs](https://commons.wikimedia.org/wiki/Category
                             :Emacs).                                           

                             [Emacs](https://en.wikibooks.org/wiki/Special:Searc
                             h/Emacs)                                           
                             [Categories](/wiki/Help:Category):                 
                             [Emacs](/wiki/Category:Emacs)[1970s in             
                             computing](/wiki/Category:1970s_in_computing)[1976 
                             software](/wiki/Category:1976_software)[Free file  
                             comparison                                         
                             tools](/wiki/Category:Free_file_comparison_tools)[F
                             ree integrated development                         
                             environments](/wiki/Category:Free_integrated_develo
                             pment_environments)[Free software programmed in    
                             C](/wiki/Category:Free_software_programmed_in_C)[Fr
                             ee software programmed in                          
                             Lisp](/wiki/Category:Free_software_programmed_in_Li
                             sp)[Free text                                      
                             editors](/wiki/Category:Free_text_editors)[Hex     
                             editors](/wiki/Category:Hex_editors)[Linux         
                             integrated development                             
                             environments](/wiki/Category:Linux_integrated_devel
                             opment_environments)[Linux text                    
                             editors](/wiki/Category:Linux_text_editors)[MacOS  
                             text                                               
                             editors](/wiki/Category:MacOS_text_editors)[OpenVMS
                             text                                               
                             editors](/wiki/Category:OpenVMS_text_editors)[Unix 
                             text                                               
                             editors](/wiki/Category:Unix_text_editors)[Windows 
                             text editors](/wiki/Category:Windows_text_editors) 
[03/12/25 20:30:49] INFO     PromptTask f8c230adb8a44485995e92b17d7847fa        
                             Output: Here's a comparison of Vim and Emacs based 
                             on the information retrieved:                      

                             ### Vim                                            
                             - **Origin**: Vim, short for "Vi IMproved," is a   
                             free and open-source text editor that is an        
                             enhanced version of the vi editor. It was created  
                             by Bram Moolenaar and first released in 1991.      
                             - **Design**: Vim is designed for both command-line
                             interface and graphical user interface use. It is  
                             known for its efficiency in text editing, allowing 
                             users to perform complex text manipulations with   
                             minimal keystrokes.                                
                             - **Features**: Vim supports syntax highlighting,  
                             code folding, spell checking, and a wide range of  
                             plugins. It is highly customizable through scripts 
                             written in Vim script or other languages like      
                             Python and Lua.                                    
                             - **Modes**: Vim operates in different modes, such 
                             as normal, insert, visual, and command-line modes, 
                             which allow for different types of text            
                             manipulation.                                      
                             - **Popularity**: Vim is popular among developers  
                             for its speed and efficiency, especially in        
                             environments where keyboard-centric navigation is  
                             preferred.                                         
                             - **License**: Vim is released under a license that
                             encourages donations to charity, specifically to   
                             help children in Uganda.                           

                             ### Emacs                                          
                             - **Origin**: Emacs is a family of text editors    
                             that began development in the mid-1970s. The most  
                             popular version, GNU Emacs, was created by Richard 
                             Stallman for the GNU Project.                      
                             - **Design**: Emacs is known for its extensibility 
                             and is often described as an "extensible,          
                             customizable, self-documenting, real-time display  
                             editor." It uses Emacs Lisp as its scripting       
                             language.                                          
                             - **Features**: Emacs offers a wide range of       
                             features, including text editing, file management, 
                             email, news reading, and more. It supports a vast  
                             number of extensions and can be customized to      
                             perform almost any task.                           
                             - **Modes**: Emacs uses modes to provide           
                             context-specific editing capabilities, such as     
                             major modes for different programming languages and
                             minor modes for additional features.               
                             - **Popularity**: Emacs is favored by users who    
                             appreciate its extensibility and the ability to    
                             customize it to suit their workflow. It is also    
                             part of the traditional "editor wars" with vi/Vim. 
                             - **License**: Emacs is free software, released    
                             under the GNU General Public License.              

                             ### Contrast                                       
                             - **User Interface**: Vim is more keyboard-centric 
                             with a steeper learning curve due to its modal     
                             nature, while Emacs offers a more traditional      
                             interface with extensive use of keybindings.       
                             - **Extensibility**: Emacs is often considered more
                             extensible due to its use of Emacs Lisp, allowing  
                             users to write complex extensions and applications 
                             within the editor.                                 
                             - **Community and Culture**: Both editors have     
                             strong communities and are part of the "editor     
                             wars," with users often having strong preferences  
                             for one over the other.                            
                             - **Learning Curve**: Vim's modal interface can be 
                             challenging for new users, while Emacs requires    
                             learning Emacs Lisp for deeper customization.      

                             Both Vim and Emacs are powerful text editors with  
                             unique features and capabilities, catering to      
                             different user preferences and workflows.          

Important

Disabling reflection will prevent the LLM from using one Tool to inform the use of another Tool. Instead, you must coordinate the Tool uses yourself.

Images

If the model supports it, you can also pass image inputs:

from griptape.loaders import ImageLoader
from griptape.structures import Agent

agent = Agent()

image_artifact = ImageLoader().load("tests/resources/mountain.jpg")

agent.run([image_artifact, "What's in this image?"])
[02/27/25 20:27:37] INFO     PromptTask 8a37d3f6f3d04fad9529d2eda571e1d3        
                             Input: Image, format: jpeg, size: 82351 bytes      

                             What's in this image?                              
[02/27/25 20:27:41] INFO     PromptTask 8a37d3f6f3d04fad9529d2eda571e1d3        
                             Output: This image depicts a stunning mountain     
                             landscape at sunrise or sunset. The scene features 
                             a prominent, snow-capped peak surrounded by other  
                             mountains. A layer of clouds or mist fills the     
                             valleys, creating a dramatic and serene atmosphere.
                             The sky is a mix of warm colors, with the sun      
                             casting a golden light over the scene.             

Tool Task

Warning

ToolTask is deprecated and will be removed in a future version. Use Prompt Task with reflect_on_tool_use set to False instead.

Another way to use Griptape Tools, is with a Tool Task. This Task takes in a single Tool which the LLM will use without Chain of Thought (CoT) reasoning. Because this Task does not use CoT, it is better suited for less capable models.

from griptape.structures import Agent
from griptape.tasks import ToolTask
from griptape.tools import CalculatorTool

# Initialize the agent and add a task
agent = Agent()
agent.add_task(ToolTask(tool=CalculatorTool()))

# Run the agent with a prompt
agent.run("Give me the answer for 5*4.")
[02/27/25 20:25:52] INFO     ToolTask c0fdc8a8558748848925ef124f5baf81          
                             Input: Give me the answer for 5*4.                 
[02/27/25 20:25:55] INFO     Subtask 0bc8ebc0ee5844ebbe855200a3eed528           
                             Actions: [                                         
                               {                                                
                                 "tag": "call_1hRhGmbBiYIzYbnjoxzmdn9M",        
                                 "name": "CalculatorTool",                      
                                 "path": "calculate",                           
                                 "input": {                                     
                                   "values": {                                  
                                     "expression": "5*4"                        
                                   }                                            
                                 }                                              
                               }                                                
                             ]                                                  
                    INFO     Subtask 0bc8ebc0ee5844ebbe855200a3eed528           
                             Response: 20                                       
                    INFO     ToolTask c0fdc8a8558748848925ef124f5baf81          
                             Output: 20                                         

Extraction Task

To extract information from text, use an ExtractionTask. This Task takes an Extraction Engine, and a set of arguments specific to the Engine.

CSV Extraction

from griptape.drivers.prompt.openai import OpenAiChatPromptDriver
from griptape.engines import CsvExtractionEngine
from griptape.structures import Agent
from griptape.tasks import ExtractionTask

# Instantiate the CSV extraction engine
csv_extraction_engine = CsvExtractionEngine(
    prompt_driver=OpenAiChatPromptDriver(model="gpt-3.5-turbo"), column_names=["Name", "Age", "Address"]
)

# Define some unstructured data and columns
csv_data = """
Alice, 28, lives in New York.
Bob, 35 lives in California.
Charlie is 40 and lives in Texas.
"""


# Create an agent and add the ExtractionTask to it
agent = Agent()
agent.add_task(
    ExtractionTask(
        extraction_engine=csv_extraction_engine,
    )
)

# Run the agent
agent.run(csv_data)
[02/27/25 20:27:00] INFO     ExtractionTask ecca0bc4f23d4b36860bf85ef127fc0e    
                             Input:                                             
                             Alice, 28, lives in New York.                      
                             Bob, 35 lives in California.                       
                             Charlie is 40 and lives in Texas.                  

[02/27/25 20:27:01] INFO     ExtractionTask ecca0bc4f23d4b36860bf85ef127fc0e    
                             Output: Name,Age,Address                           
                             Alice,28,lives in New York.                        
                             Bob,35,lives in California.                        
                             Charlie,40,lives in Texas.                         

JSON Extraction

from schema import Schema

from griptape.drivers.prompt.openai import OpenAiChatPromptDriver
from griptape.engines import JsonExtractionEngine
from griptape.structures import Agent
from griptape.tasks import ExtractionTask

# Instantiate the json extraction engine
json_extraction_engine = JsonExtractionEngine(
    prompt_driver=OpenAiChatPromptDriver(model="gpt-3.5-turbo"),
    template_schema=Schema({"users": [{"name": str, "age": int, "location": str}]}).json_schema("UserSchema"),
)

# Define some unstructured data and a schema
json_data = """
Alice (Age 28) lives in New York.
Bob (Age 35) lives in California.
"""

agent = Agent()
agent.add_task(
    ExtractionTask(
        extraction_engine=json_extraction_engine,
    )
)

# Run the agent
agent.run(json_data)
[02/27/25 20:27:33] INFO     ExtractionTask cc243ff09ee84a1e8616b97895618aac    
                             Input:                                             
                             Alice (Age 28) lives in New York.                  
                             Bob (Age 35) lives in California.                  

[02/27/25 20:27:34] INFO     ExtractionTask cc243ff09ee84a1e8616b97895618aac    
                             Output: {"name": "Alice", "age": 28, "location":   
                             "New York"}                                        
                             {"name": "Bob", "age": 35, "location":             
                             "California"}                                      

Text Summary Task

To summarize a text, use the TextSummaryTask. This Task takes an Summarization Engine, and a set of arguments to the engine.

from griptape.structures import Agent
from griptape.tasks import TextSummaryTask

# Create a new agent
agent = Agent()

# Add the TextSummaryTask to the agent
agent.add_task(TextSummaryTask())


# Run the agent
agent.run(
    "Artificial Intelligence (AI) is a branch of computer science that deals with "
    "creating machines capable of thinking and learning. It encompasses various fields "
    "such as machine learning, neural networks, and deep learning. AI has the potential "
    "to revolutionize many sectors, including healthcare, finance, and transportation. "
    "Our life in this modern age depends largely on computers. It is almost impossible "
    "to think about life without computers. We need computers in everything that we use "
    "in our daily lives. So it becomes very important to make computers intelligent so "
    "that our lives become easy. Artificial Intelligence is the theory and development "
    "of computers, which imitates the human intelligence and senses, such as visual "
    "perception, speech recognition, decision-making, and translation between languages."
    " Artificial Intelligence has brought a revolution in the world of technology. "
)
[02/27/25 20:26:48] INFO     TextSummaryTask 987b9b66ee1a45f1b720e3a90e603a7f   
                             Input: Artificial Intelligence (AI) is a branch of 
                             computer science that deals with creating machines 
                             capable of thinking and learning. It encompasses   
                             various fields such as machine learning, neural    
                             networks, and deep learning. AI has the potential  
                             to revolutionize many sectors, including           
                             healthcare, finance, and transportation. Our life  
                             in this modern age depends largely on computers. It
                             is almost impossible to think about life without   
                             computers. We need computers in everything that we 
                             use in our daily lives. So it becomes very         
                             important to make computers intelligent so that our
                             lives become easy. Artificial Intelligence is the  
                             theory and development of computers, which imitates
                             the human intelligence and senses, such as visual  
                             perception, speech recognition, decision-making,   
                             and translation between languages. Artificial      
                             Intelligence has brought a revolution in the world 
                             of technology.                                     
[02/27/25 20:26:51] INFO     TextSummaryTask 987b9b66ee1a45f1b720e3a90e603a7f   
                             Output: Artificial Intelligence (AI), a branch of  
                             computer science, focuses on creating machines that
                             can think and learn, involving fields like machine 
                             learning, neural networks, and deep learning. AI   
                             has the potential to transform sectors such as     
                             healthcare, finance, and transportation. As modern 
                             life heavily relies on computers, making them      
                             intelligent is crucial for simplifying daily tasks.
                             AI aims to mimic human intelligence and senses,    
                             including visual perception, speech recognition,   
                             decision-making, and language translation, leading 
                             to a technological revolution.                     

RAG Task

To query text, use the RagTask. This task takes a RAG Engine, and a set of arguments specific to the engine.

from griptape.artifacts import TextArtifact
from griptape.drivers.embedding.openai import OpenAiEmbeddingDriver
from griptape.drivers.prompt.openai import OpenAiChatPromptDriver
from griptape.drivers.vector.local import LocalVectorStoreDriver
from griptape.engines.rag import RagEngine
from griptape.engines.rag.modules import PromptResponseRagModule, VectorStoreRetrievalRagModule
from griptape.engines.rag.stages import ResponseRagStage, RetrievalRagStage
from griptape.structures import Agent
from griptape.tasks import RagTask

# Initialize Embedding Driver and Vector Store Driver
vector_store_driver = LocalVectorStoreDriver(embedding_driver=OpenAiEmbeddingDriver())

artifacts = [
    TextArtifact("Griptape builds AI-powered applications that connect securely to your enterprise data and APIs."),
    TextArtifact("Griptape Agents provide incredible power and flexibility when working with large language models."),
]
vector_store_driver.upsert_collection({"griptape": artifacts})

# Instantiate the agent and add RagTask with the RagEngine
agent = Agent()
agent.add_task(
    RagTask(
        "Respond to the following query: {{ args[0] }}",
        rag_engine=RagEngine(
            retrieval_stage=RetrievalRagStage(
                retrieval_modules=[
                    VectorStoreRetrievalRagModule(
                        vector_store_driver=vector_store_driver, query_params={"namespace": "griptape", "top_n": 20}
                    )
                ]
            ),
            response_stage=ResponseRagStage(
                response_modules=[PromptResponseRagModule(prompt_driver=OpenAiChatPromptDriver(model="gpt-4o"))]
            ),
        ),
    )
)

# Run the agent with a query string
agent.run("Give me information about Griptape")
[03/13/25 22:50:19] INFO     RagTask 9fad9b308bb84c4084c005492a7e7baf           
                             Input: Respond to the following query: Give me     
                             information about Griptape                         
[03/13/25 22:50:20] INFO     RagTask 9fad9b308bb84c4084c005492a7e7baf           
                             Output: Griptape builds AI-powered applications    
                             that connect securely to your enterprise data and  
                             APIs. Additionally, Griptape Agents offer          
                             incredible power and flexibility when working with 
                             large language models.                             

Code Execution Task

To execute an arbitrary Python function, use the CodeExecutionTask. This task takes a python function, and authors can elect to return a custom artifact.

In this example, the generate_title function combines a hero's name and setting from previous tasks with a random title, returning a TextArtifact that contains the generated fantasy title. The output of this task can then be referenced by subsequent tasks using the parent_outputs templating variable, as shown in the final PromptTask.

import random

from griptape.artifacts import BaseArtifact, TextArtifact
from griptape.structures import Workflow
from griptape.tasks import CodeExecutionTask, PromptTask
from griptape.utils import StructureVisualizer


# Define a function that will generate a fantasy title by combining inputs
def generate_title(task: CodeExecutionTask) -> BaseArtifact:
    # Make sure this is part of a valid structure
    structure = task.structure
    if structure is None:
        raise ValueError("Task must be part of a structure to run")

    # Retrieve outputs from previous tasks using their task IDs
    hero = structure.find_task("hero").output  # Gets the hero name from first prompt
    setting = structure.find_task("setting").output  # Gets the setting from second prompt

    # List of epic titles to randomly choose from
    titles = ["the Brave", "the Shadow", "the Flame", "the Eternal", "the Cursed"]
    # Combine the hero name, random title, and setting into a full title
    generated_title = f"{hero} {random.choice(titles)} of {setting}"

    # Return the generated title as a TextArtifact that can be used by other tasks
    return TextArtifact(generated_title)


# Create a new workflow to organize our tasks
workflow = Workflow()

# Add a sequence of connected tasks to the workflow
workflow.add_tasks(
    # First task: Prompt for a hero name
    # The child_ids parameter connects this to the generate_title task
    PromptTask("Name a fantasy hero (e.g., 'Eldric')", id="hero", child_ids=["generate_title"]),
    # Second task: Prompt for a setting
    # Also connected to generate_title task
    PromptTask(
        "Describe a mystical setting in a couple sentences (e.g., 'the Shattered Isles')",
        id="setting",
        child_ids=["generate_title"],
    ),
    # Third task: Execute our custom code to generate the title
    # The on_run parameter specifies which function to execute
    CodeExecutionTask(on_run=generate_title, id="generate_title", child_ids=["story"]),
    # Fourth task: Prompt for a story using the generated title
    # {{ parent_outputs['generate_title'] }} references the output from the previous task
    PromptTask(
        "Write a brief, yet heroic tale about {{ parent_outputs['generate_title'] }}. ",
        id="story",
    ),
)

# Visualize the workflow structure (helpful for debugging)
print(StructureVisualizer(workflow).to_url())

# Execute the entire workflow
workflow.run()
https://mermaid.ink/svg/Z3JhcGggVEQ7CglIZXJvLS0+IEdlbmVyYXRlX1RpdGxlOwoJU2V0dGluZy0tPiBHZW5lcmF0ZV9UaXRsZTsKCUdlbmVyYXRlX1RpdGxlLS0+IFN0b3J5OwoJU3Rvcnk7
[02/27/25 20:33:34] INFO     PromptTask hero                                    
                             Input: Name a fantasy hero (e.g., 'Eldric')        
                    INFO     PromptTask setting                                 
                             Input: Describe a mystical setting in a couple     
                             sentences (e.g., 'the Shattered Isles')            
[02/27/25 20:33:35] INFO     PromptTask hero                                    
                             Output: Sure! How about "Thalorin"?                
[02/27/25 20:33:36] INFO     PromptTask setting                                 
                             Output: The Luminous Glade is a hidden realm where 
                             twilight never fades, and the air shimmers with    
                             ethereal light. Ancient trees with silver bark and 
                             luminescent leaves form a canopy overhead, while   
                             bioluminescent flora carpet the forest floor,      
                             casting a gentle glow that dances with the whispers
                             of the wind. In the heart of the glade lies a      
                             serene lake, its waters reflecting the starry sky  
                             above, where mythical creatures gather to drink    
                             from its enchanted depths.                         
                    INFO     PromptTask story                                   
                             Input: Write a brief, yet heroic tale about Sure!  
                             How about "Thalorin"? the Eternal of The Luminous  
                             Glade is a hidden realm where twilight never fades,
                             and the air shimmers with ethereal light. Ancient  
                             trees with silver bark and luminescent leaves form 
                             a canopy overhead, while bioluminescent flora      
                             carpet the forest floor, casting a gentle glow that
                             dances with the whispers of the wind. In the heart 
                             of the glade lies a serene lake, its waters        
                             reflecting the starry sky above, where mythical    
                             creatures gather to drink from its enchanted       
                             depths..                                           
[02/27/25 20:33:41] INFO     PromptTask story                                   
                             Output: In the heart of the Luminous Glade, where  
                             twilight never fades and the air shimmers with     
                             ethereal light, dwelled Thalorin, the Eternal.     
                             Guardian of this hidden realm, Thalorin was a being
                             of ancient wisdom and unmatched valor, his presence
                             as timeless as the silver-barked trees that formed 
                             the glade's canopy.                                

                             One fateful eve, a shadow crept into the glade, a  
                             dark force seeking to extinguish its eternal       
                             twilight. The creatures of the forest, from the    
                             smallest luminescent insects to the majestic       
                             starlit deer, trembled as the darkness spread,     
                             threatening to consume their sanctuary.            

                             Sensing the peril, Thalorin emerged from the depths
                             of the serene lake, his form shimmering with the   
                             light of a thousand stars. With a voice that       
                             resonated like the gentle rustle of leaves, he     
                             called upon the ancient magic of the glade. The    
                             trees responded, their luminescent leaves glowing  
                             brighter, casting beams of light that pierced the  
                             encroaching shadow.                                

                             The battle was fierce, the darkness relentless, but
                             Thalorin stood undeterred. Drawing strength from   
                             the enchanted waters and the bioluminescent flora, 
                             he wove a tapestry of light, a radiant barrier that
                             pushed back the shadow. The mythical creatures     
                             gathered around him, lending their own magic to the
                             cause, their unity a beacon of hope.               

                             In a final, heroic surge, Thalorin unleashed the   
                             full power of the glade, a blinding burst of light 
                             that shattered the darkness, restoring peace and   
                             balance. The shadow vanquished, the glade's        
                             twilight glow returned, more vibrant than ever.    

                             As the creatures celebrated their victory,         
                             Thalorin, the Eternal, stood watchful, a silent    
                             guardian of the Luminous Glade. His tale of heroism
                             would echo through the ages, a reminder of the     
                             light that dwells within, even in the face of the  
                             deepest shadows.                                   

Branch Task

By default, a Workflow will only run a Task when all the Tasks it depends on have finished.

You can make use of BranchTask in order to tell the Workflow not to run all dependent tasks, but instead to pick and choose one or more paths to go down.

The BranchTask's on_run function can return one of three things:

  1. An InfoArtifact containing the id of the Task to run next.
  2. A ListArtifact of InfoArtifacts containing the ids of the Tasks to run next.
  3. An empty ListArtifact to indicate that no Tasks should be run next.
from griptape.artifacts import InfoArtifact
from griptape.loaders import ImageLoader
from griptape.structures import Workflow
from griptape.tasks import BranchTask, PromptTask


def on_run(task: BranchTask) -> InfoArtifact:
    if "hot dog" in task.input.value:
        return InfoArtifact("hot_dog")
    return InfoArtifact("not_hot_dog")


image_artifact = ImageLoader().load("tests/resources/mountain.png")

workflow = Workflow(
    tasks=[
        PromptTask(["What is in this image?", image_artifact], child_ids=["branch"]),
        BranchTask(
            "{{ parents_output_text }}",
            on_run=on_run,
            id="branch",
            child_ids=["hot_dog", "not_hot_dog"],
        ),
        PromptTask("Tell me about hot dogs", id="hot_dog"),
        PromptTask("Tell me about anything but hotdogs", id="not_hot_dog"),
    ]
)

workflow.run()
[02/27/25 20:25:31] INFO     PromptTask e34a33e50d694fe5958fac4897e0bffe        
                             Input: What is in this image?                      

                             Image, format: png, size: 436989 bytes             
[02/27/25 20:25:35] INFO     PromptTask e34a33e50d694fe5958fac4897e0bffe        
                             Output: The image depicts a stunning mountain      
                             landscape at sunrise or sunset. The sun is         
                             partially visible on the horizon, casting a warm   
                             glow over the scene. The mountains are covered with
                             snow at their peaks, and a layer of clouds or mist 
                             is settled in the valleys, creating a serene and   
                             majestic atmosphere. The sky is a mix of orange,   
                             pink, and blue hues, with some clouds adding       
                             texture to the scene.                              
                    INFO     PromptTask not_hot_dog                             
                             Input: Tell me about anything but hotdogs          
[02/27/25 20:25:38] INFO     PromptTask not_hot_dog                             
                             Output: Sure! Let's talk about sushi. Sushi is a   
                             traditional Japanese dish that has become popular  
                             worldwide. It typically consists of vinegared rice 
                             paired with a variety of ingredients, such as      
                             seafood, vegetables, and occasionally tropical     
                             fruits. Sushi can be presented in several forms,   
                             including:                                         

                             1. **Nigiri**: Small rice balls topped with a slice
                             of fish or other seafood.                          
                             2. **Sashimi**: Thinly sliced raw fish or seafood, 
                             served without rice.                               
                             3. **Maki**: Rice and fillings rolled in seaweed   
                             (nori) and sliced into bite-sized pieces.          
                             4. **Uramaki**: Similar to maki, but with the rice 
                             on the outside and the seaweed wrapping the        
                             fillings.                                          
                             5. **Temaki**: Cone-shaped hand rolls filled with  
                             rice, seafood, and vegetables.                     

                             Sushi is often accompanied by soy sauce, pickled   
                             ginger, and wasabi, which enhance its flavors. It's
                             a versatile dish that can range from simple to     
                             elaborate, making it a favorite for both casual    
                             dining and special occasions.                      

Image Generation Tasks

To generate an image, use one of the following Image Generation Tasks. All Image Generation Tasks accept an Image Generation Driver.

All successful Image Generation Tasks will always output an Image Artifact. Each task can be configured to additionally write the generated image to disk by providing either the output_file or output_dir field. The output_file field supports file names in the current directory (my_image.png), relative directory prefixes (images/my_image.png), or absolute paths (/usr/var/my_image.png). By setting output_dir, the task will generate a file name and place the image in the requested directory.

Prompt Image Generation Task

The Prompt Image Generation Task generates an image from a text prompt.

from griptape.drivers.image_generation.openai import OpenAiImageGenerationDriver
from griptape.structures import Pipeline
from griptape.tasks import PromptImageGenerationTask

# Create a driver configured to use OpenAI's DALL-E 3 model.
driver = OpenAiImageGenerationDriver(
    model="dall-e-3",
    quality="hd",
    style="natural",
)


# Instantiate a pipeline.
pipeline = Pipeline()

# Add a PromptImageGenerationTask to the pipeline.
pipeline.add_tasks(
    PromptImageGenerationTask(
        input="{{ args[0] }}",
        image_generation_driver=driver,
        output_dir="images/",
    )
)

pipeline.run("An image of a mountain on a summer day")

Variation Image Generation Task

The Variation Image Generation Task generates an image using an input image and a text prompt. The input image is used as a basis for generating a new image as requested by the text prompt.

from griptape.drivers.image_generation.amazon_bedrock import AmazonBedrockImageGenerationDriver
from griptape.drivers.image_generation_model.bedrock_stable_diffusion import (
    BedrockStableDiffusionImageGenerationModelDriver,
)
from griptape.loaders import ImageLoader
from griptape.structures import Pipeline
from griptape.tasks import VariationImageGenerationTask

# Create a driver configured to use Stable Diffusion via Bedrock.
driver = AmazonBedrockImageGenerationDriver(
    image_generation_model_driver=BedrockStableDiffusionImageGenerationModelDriver(),
    model="stability.stable-diffusion-xl-v1",
)


# Load input image artifact.
image_artifact = ImageLoader().load("tests/resources/mountain.png")

# Instantiate a pipeline.
pipeline = Pipeline()

# Add a VariationImageGenerationTask to the pipeline.
pipeline.add_task(
    VariationImageGenerationTask(
        input=("{{ args[0] }}", image_artifact),
        image_generation_driver=driver,
        output_dir="images/",
    )
)

pipeline.run("An image of a mountain landscape on a snowy winter day")

Inpainting Image Generation Task

The Inpainting Image Generation Task generates an image using an input image, a mask image, and a text prompt. The input image will be modified within the bounds of the mask image as requested by the text prompt.

from griptape.drivers.image_generation.amazon_bedrock import AmazonBedrockImageGenerationDriver
from griptape.drivers.image_generation_model.bedrock_stable_diffusion import (
    BedrockStableDiffusionImageGenerationModelDriver,
)
from griptape.loaders import ImageLoader
from griptape.structures import Pipeline
from griptape.tasks import InpaintingImageGenerationTask

# Create a driver configured to use Stable Diffusion via Bedrock.
driver = AmazonBedrockImageGenerationDriver(
    image_generation_model_driver=BedrockStableDiffusionImageGenerationModelDriver(),
    model="stability.stable-diffusion-xl-v1",
)

# Load input image artifacts.
image_artifact = ImageLoader().load("tests/resources/mountain.png")

mask_artifact = ImageLoader().load("tests/resources/mountain-mask.png")

# Instantiate a pipeline.
pipeline = Pipeline()

# Add an InpaintingImageGenerationTask to the pipeline.
pipeline.add_task(
    InpaintingImageGenerationTask(
        input=("{{ args[0] }}", image_artifact, mask_artifact), image_generation_driver=driver, output_dir="images/"
    )
)

pipeline.run("An image of a castle built into the side of a mountain")

Outpainting Image Generation Task

The Outpainting Image Generation Task generates an image using an input image, a mask image, and a text prompt. The input image will be modified outside the bounds of a mask image as requested by the text prompt.

from griptape.drivers.image_generation.amazon_bedrock import AmazonBedrockImageGenerationDriver
from griptape.drivers.image_generation_model.bedrock_stable_diffusion import (
    BedrockStableDiffusionImageGenerationModelDriver,
)
from griptape.loaders import ImageLoader
from griptape.structures import Pipeline
from griptape.tasks import OutpaintingImageGenerationTask

# Create a driver configured to use Stable Diffusion via Bedrock.
driver = AmazonBedrockImageGenerationDriver(
    image_generation_model_driver=BedrockStableDiffusionImageGenerationModelDriver(),
    model="stability.stable-diffusion-xl-v1",
)


# Load input image artifacts.
image_artifact = ImageLoader().load("tests/resources/mountain.png")

mask_artifact = ImageLoader().load("tests/resources/mountain-mask.png")

# Instantiate a pipeline.
pipeline = Pipeline()

# Add an OutpaintingImageGenerationTask to the pipeline.
pipeline.add_task(
    OutpaintingImageGenerationTask(
        input=("{{ args[0] }}", image_artifact, mask_artifact),
        image_generation_driver=driver,
        output_dir="images/",
    )
)

pipeline.run("An image of a mountain shrouded by clouds")

Structure Run Task

The Structure Run Task runs another Structure with a given input. This Task is useful for orchestrating multiple specialized Structures in a single run. Note that the input to the Task is a tuple of arguments that will be passed to the Structure.

import os

from griptape.drivers.structure_run.local import LocalStructureRunDriver
from griptape.drivers.web_search.google import GoogleWebSearchDriver
from griptape.rules import Rule, Ruleset
from griptape.structures import Agent, Pipeline
from griptape.tasks import StructureRunTask
from griptape.tools import (
    PromptSummaryTool,
    WebScraperTool,
    WebSearchTool,
)


def build_researcher() -> Agent:
    return Agent(
        tools=[
            WebSearchTool(
                web_search_driver=GoogleWebSearchDriver(
                    api_key=os.environ["GOOGLE_API_KEY"],
                    search_id=os.environ["GOOGLE_API_SEARCH_ID"],
                ),
            ),
            WebScraperTool(
                off_prompt=True,
            ),
            PromptSummaryTool(off_prompt=False),
        ],
        rulesets=[
            Ruleset(
                name="Position",
                rules=[
                    Rule(
                        value="Senior Research Analyst",
                    )
                ],
            ),
            Ruleset(
                name="Objective",
                rules=[
                    Rule(
                        value="Uncover cutting-edge developments in AI and data science",
                    )
                ],
            ),
            Ruleset(
                name="Background",
                rules=[
                    Rule(
                        value="""You work at a leading tech think tank.,
                        Your expertise lies in identifying emerging trends.
                        You have a knack for dissecting complex data and presenting actionable insights."""
                    )
                ],
            ),
            Ruleset(
                name="Desired Outcome",
                rules=[
                    Rule(
                        value="Full analysis report in bullet points",
                    )
                ],
            ),
        ],
    )


def build_writer() -> Agent:
    return Agent(
        input="Instructions: {{args[0]}}\nContext: {{args[1]}}",
        rulesets=[
            Ruleset(
                name="Position",
                rules=[
                    Rule(
                        value="Tech Content Strategist",
                    )
                ],
            ),
            Ruleset(
                name="Objective",
                rules=[
                    Rule(
                        value="Craft compelling content on tech advancements",
                    )
                ],
            ),
            Ruleset(
                name="Backstory",
                rules=[
                    Rule(
                        value="""You are a renowned Content Strategist, known for your insightful and engaging articles.
                        You transform complex concepts into compelling narratives."""
                    )
                ],
            ),
            Ruleset(
                name="Desired Outcome",
                rules=[
                    Rule(
                        value="Full blog post of at least 4 paragraphs",
                    )
                ],
            ),
        ],
    )


team = Pipeline(
    tasks=[
        StructureRunTask(
            (
                """Perform a detailed examination of the newest developments in AI as of 2024.
                Pinpoint major trends, breakthroughs, and their implications for various industries.""",
            ),
            structure_run_driver=LocalStructureRunDriver(create_structure=build_researcher),
        ),
        StructureRunTask(
            (
                """Utilize the gathered insights to craft a captivating blog
                article showcasing the key AI innovations.
                Ensure the content is engaging yet straightforward, appealing to a tech-aware readership.
                Keep the tone appealing and use simple language to make it less technical.""",
                "{{parent_output}}",
            ),
            structure_run_driver=LocalStructureRunDriver(create_structure=build_writer),
        ),
    ],
)

team.run()
[02/27/25 20:34:34] INFO     PromptTask 5c8be35339c64dbbab91af43fa8b3972        
                             Input: Perform a detailed examination of the newest
                             developments in AI as of 2024.                     
                                             Pinpoint major trends,             
                             breakthroughs, and their implications for various  
                             industries.                                        
[02/27/25 20:34:36] INFO     Subtask 6a1a242356e94a78aca3c3b3f37fab9a           
                             Actions: [                                         
                               {                                                
                                 "tag": "call_1QMuespMZzQpUujchBkW7brD",        
                                 "name": "WebSearchTool",                       
                                 "path": "search",                              
                                 "input": {                                     
                                   "values": {                                  
                                     "query": "new developments in AI 2024      
                             trends breakthroughs implications"                 
                                   }                                            
                                 }                                              
                               }                                                
                             ]                                                  
                    INFO     Subtask 6a1a242356e94a78aca3c3b3f37fab9a           
                             Response: {"url":                                  
                             "https://aiindex.stanford.edu/report/", "title":   
                             "AI Index Report 2024 \u2013 Artificial            
                             Intelligence Index", "description": "This year, we 
                             have broadened our scope to more extensively cover 
                             essential trends such as technical advancements in 
                             AI, public perceptions of the                      
                             technology,\u00a0..."}                             

                             {"url":                                            
                             "https://www.ibm.com/think/insights/artificial-inte
                             lligence-trends", "title": "The most important AI  
                             trends in 2024", "description": "Feb 9, 2024 ...   
                             According to a recent IBM survey of over 1,000     
                             employees at enterprise-scale companies, the top   
                             three factors driving AI adoption were             
                             advances\u00a0..."}                                

                             {"url":                                            
                             "https://www.cas.org/resources/cas-insights/scienti
                             fic-breakthroughs-2024-emerging-trends-watch",     
                             "title": "Scientific breakthroughs: 2024 emerging  
                             trends to watch | CAS", "description": "Dec 28,    
                             2023 ... However, continuous improvement is        
                             inevitable with AI, so expect to see many new      
                             developments and innovations throughout 2024. ...  
                             impact of new\u00a0..."}                           

                             {"url":                                            
                             "https://www.channelinsider.com/managed-services/ge
                             nerative-ai-developments-trends-year-in-review/",  
                             "title": "Generative AI Developments & Trends in   
                             2024: A Timeline", "description": "Nov 14, 2024 ...
                             Discover key milestones and advancements in        
                             generative AI for 2024, highlighting innovations   
                             and trends that will shape the future of artificial
                             intelligence."}                                    

                             {"url":                                            
                             "https://www.mckinsey.com/capabilities/mckinsey-dig
                             ital/our-insights/the-top-trends-in-tech", "title":
                             "McKinsey technology trends outlook 2024 |         
                             McKinsey", "description": "Jul 16, 2024 ... Which  
                             new technology will have the most impact in 2024   
                             and beyond ... Advancements in AI are ushering in a
                             new era of more capable robots\u00a0..."}          
[02/27/25 20:34:40] INFO     Subtask 35de039dba094b88b7dfcd0dc396177b           
                             Actions: [                                         
                               {                                                
                                 "tag": "call_kx98ttpns9saeP2K2nFDbiHA",        
                                 "name": "WebScraperTool",                      
                                 "path": "get_content",                         
                                 "input": {                                     
                                   "values": {                                  
                                     "url":                                     
                             "https://aiindex.stanford.edu/report/"             
                                   }                                            
                                 }                                              
                               },                                               
                               {                                                
                                 "tag": "call_FmoM0n5IMkmdo6wcJdYJT6lZ",        
                                 "name": "WebScraperTool",                      
                                 "path": "get_content",                         
                                 "input": {                                     
                                   "values": {                                  
                                     "url":                                     
                             "https://www.ibm.com/think/insights/artificial-inte
                             lligence-trends"                                   
                                   }                                            
                                 }                                              
                               },                                               
                               {                                                
                                 "tag": "call_x6RcRuv0ydnvQ8T208yXdC1p",        
                                 "name": "WebScraperTool",                      
                                 "path": "get_content",                         
                                 "input": {                                     
                                   "values": {                                  
                                     "url":                                     
                             "https://www.cas.org/resources/cas-insights/scienti
                             fic-breakthroughs-2024-emerging-trends-watch"      
                                   }                                            
                                 }                                              
                               },                                               
                               {                                                
                                 "tag": "call_OtuBpUpKdVlbBJ82s0ztTAls",        
                                 "name": "WebScraperTool",                      
                                 "path": "get_content",                         
                                 "input": {                                     
                                   "values": {                                  
                                     "url":                                     
                             "https://www.channelinsider.com/managed-services/ge
                             nerative-ai-developments-trends-year-in-review/"   
                                   }                                            
                                 }                                              
                               },                                               
                               {                                                
                                 "tag": "call_8ResJ7zJl4O3QgyuBLeCXGNb",        
                                 "name": "WebScraperTool",                      
                                 "path": "get_content",                         
                                 "input": {                                     
                                   "values": {                                  
                                     "url":                                     
                             "https://www.mckinsey.com/capabilities/mckinsey-dig
                             ital/our-insights/the-top-trends-in-tech"          
                                   }                                            
                                 }                                              
                               }                                                
                             ]                                                  
[02/27/25 20:34:56] INFO     Subtask 35de039dba094b88b7dfcd0dc396177b           
                             Response: Output of "WebScraperTool.get_content"   
                             was stored in memory with memory_name "TaskMemory" 
                             and artifact_namespace                             
                             "958b71e86e3a4bb09ad3752b54a06069"                 

                             Output of "WebScraperTool.get_content" was stored  
                             in memory with memory_name "TaskMemory" and        
                             artifact_namespace                                 
                             "cee8d6129baa4e27879dd35775e18292"                 

                             Output of "WebScraperTool.get_content" was stored  
                             in memory with memory_name "TaskMemory" and        
                             artifact_namespace                                 
                             "88136c66909342dab1def2d27657c767"                 

                             Output of "WebScraperTool.get_content" was stored  
                             in memory with memory_name "TaskMemory" and        
                             artifact_namespace                                 
                             "61a364e7ce3f481a87450d6d25ed8d3a"                 

                             Output of "WebScraperTool.get_content" was stored  
                             in memory with memory_name "TaskMemory" and        
                             artifact_namespace                                 
                             "c5c6bae41e944fc5b2da265210359308"                 
[02/27/25 20:35:01] INFO     Subtask 17c63ccf252f41b48698e73f2070cbad           
                             Actions: [                                         
                               {                                                
                                 "tag": "call_0teuTCNqgeVBY9wQe8wDMvNl",        
                                 "name": "PromptSummaryTool",                   
                                 "path": "summarize",                           
                                 "input": {                                     
                                   "values": {                                  
                                     "summary": {                               
                                       "memory_name": "TaskMemory",             
                                       "artifact_namespace":                    
                             "958b71e86e3a4bb09ad3752b54a06069"                 
                                     }                                          
                                   }                                            
                                 }                                              
                               },                                               
                               {                                                
                                 "tag": "call_KUH0lEOg0HOoZ3MTr6B8d97Z",        
                                 "name": "PromptSummaryTool",                   
                                 "path": "summarize",                           
                                 "input": {                                     
                                   "values": {                                  
                                     "summary": {                               
                                       "memory_name": "TaskMemory",             
                                       "artifact_namespace":                    
                             "cee8d6129baa4e27879dd35775e18292"                 
                                     }                                          
                                   }                                            
                                 }                                              
                               },                                               
                               {                                                
                                 "tag": "call_7U9IA5JjBiRo5CC3tMKvbp7s",        
                                 "name": "PromptSummaryTool",                   
                                 "path": "summarize",                           
                                 "input": {                                     
                                   "values": {                                  
                                     "summary": {                               
                                       "memory_name": "TaskMemory",             
                                       "artifact_namespace":                    
                             "88136c66909342dab1def2d27657c767"                 
                                     }                                          
                                   }                                            
                                 }                                              
                               },                                               
                               {                                                
                                 "tag": "call_CYoRuS9a8UEwQSUz9h0SxQbt",        
                                 "name": "PromptSummaryTool",                   
                                 "path": "summarize",                           
                                 "input": {                                     
                                   "values": {                                  
                                     "summary": {                               
                                       "memory_name": "TaskMemory",             
                                       "artifact_namespace":                    
                             "61a364e7ce3f481a87450d6d25ed8d3a"                 
                                     }                                          
                                   }                                            
                                 }                                              
                               },                                               
                               {                                                
                                 "tag": "call_p37C25sjh3zZnsU499LFLuah",        
                                 "name": "PromptSummaryTool",                   
                                 "path": "summarize",                           
                                 "input": {                                     
                                   "values": {                                  
                                     "summary": {                               
                                       "memory_name": "TaskMemory",             
                                       "artifact_namespace":                    
                             "c5c6bae41e944fc5b2da265210359308"                 
                                     }                                          
                                   }                                            
                                 }                                              
                               }                                                
                             ]                                                  
[02/27/25 20:35:05] INFO     Subtask 17c63ccf252f41b48698e73f2070cbad           
                             Response: The 2024 AI Index Report, the seventh    
                             edition, is the most comprehensive yet, reflecting 
                             AI's growing societal influence. It covers         
                             technical advancements, public perceptions, and    
                             geopolitical dynamics, with new data on AI training
                             costs and responsible AI. AI has surpassed human   
                             performance in some areas but lags in complex      
                             tasks. In 2023, industry led AI model production,  
                             with significant U.S. contributions. Training costs
                             for models like GPT-4 and Gemini Ultra are         
                             unprecedented. Despite a decline in overall AI     
                             investment, generative AI funding surged. AI       
                             impacts labor by enhancing productivity but poses  
                             risks without oversight. AI's role in scientific   
                             discovery and medicine is expanding, with notable  
                             applications like AlphaDev and GNoME. AI-related   
                             regulations in the U.S. have increased             
                             significantly. Public concern about AI is rising,  
                             with many expressing nervousness. The report       
                             examines AI's integration into various sectors,    
                             responsible AI development, economic impacts, and  
                             educational trends. It highlights diversity issues 
                             in AI development and the importance of            
                             understanding public perceptions. The report aims  
                             to provide unbiased data to inform policymakers,   
                             researchers, and the public.                       

                             The text discusses the rapid evolution and         
                             integration of generative AI into the business     
                             world, highlighting 2024 as a pivotal year for its 
                             development. It compares the growth of generative  
                             AI to the historical development of computers,     
                             noting that AI has reached a "hobbyist" phase with 
                             open-source models like Meta’s LlaMa and others    
                             gaining prominence. The focus is shifting towards  
                             making AI more trustworthy, sustainable, and       
                             accessible, with trends indicating a move towards  
                             smaller, more efficient models. Multimodal AI,     
                             which can process diverse data types, is expected  
                             to enhance AI applications and virtual assistants. 
                             However, challenges such as regulatory issues,     
                             potential misuse, and the need for responsible AI  
                             adoption are emphasized. The text also highlights  
                             the importance of proprietary data pipelines and   
                             the risks associated with "shadow AI" in           
                             workplaces. Overall, the document underscores the  
                             need for businesses to adapt to emerging AI trends 
                             to maximize potential and minimize risks.          

                             The text discusses emerging scientific trends and  
                             breakthroughs across various fields. In 2024,      
                             notable trends include advancements in green       
                             chemistry, clinical validation of CRISPR, the rise 
                             of biomaterials, and progress in treating          
                             previously undruggable diseases. AI is increasingly
                             impacting R&D, with applications in drug discovery 
                             and healthcare, despite concerns about data        
                             accuracy and bias. Green chemistry is focusing on  
                             reducing plastics, developing sustainable          
                             catalysts, and recycling lithium-ion batteries.    
                             Biomaterials are advancing in biomedical           
                             applications, such as bioelectronic materials and  
                             3D-printed organs. The Artemis space program aims  
                             to enhance space exploration and related           
                             technologies. CRISPR technology is making strides  
                             in therapeutic applications, with significant      
                             approvals for treating genetic diseases.           
                             Immuno-oncology is evolving with personalized      
                             therapies and novel strategies. Efforts to         
                             decarbonize energy include developing large-scale  
                             energy storage and nuclear power advancements. In  
                             neurodegenerative diseases, new treatments and     
                             diagnostics are emerging for Alzheimer's,          
                             Parkinson's, and ALS.                              

                             The rise of generative AI (GenAI) is significantly 
                             transforming the business landscape by enhancing   
                             productivity and streamlining operations. GenAI,   
                             which creates new content like text, images, and   
                             audio, differs from traditional AI by producing    
                             unique outputs based on large datasets. It is      
                             expected to add trillions to the global economy and
                             is being integrated into various sectors, including
                             healthcare, IT, and retail. Key developments in    
                             2024 include collaborations and innovations by     
                             companies like Cerebras Systems, Cisco, and OpenAI,
                             highlighting GenAI's growing influence. For managed
                             service providers (MSPs), staying updated on GenAI 
                             tools and trends is crucial to guide businesses in 
                             leveraging AI effectively. GenAI offers            
                             opportunities for content creation, personalized   
                             customer experiences, task automation, and enhanced
                             decision-making. MSPs can support AI adoption by   
                             providing seamless integration, ensuring data      
                             security, and offering training. As GenAI continues
                             to evolve, it presents both opportunities and      
                             challenges, such as data security concerns and     
                             potential job displacement. MSPs that adapt to     
                             these changes can position themselves as key       
                             partners in their customers' digital transformation
                             journeys.                                          

                             Despite challenging market conditions in 2023,     
                             investments in frontier technologies, particularly 
                             generative AI (gen AI) and electrification and     
                             renewables, promise substantial future growth in   
                             enterprise adoption. Gen AI has seen a significant 
                             increase in interest and investment, driving       
                             innovation in related fields like robotics and     
                             immersive reality. The McKinsey Technology Trends  
                             Outlook highlights these trends, emphasizing the   
                             importance of understanding potential use cases,   
                             value sources, and necessary skills. While overall 
                             technology equity investments fell due to economic 
                             factors, gen AI experienced a sevenfold increase in
                             investments. Electrification and renewables also   
                             maintained high interest and investment levels.    
                             Despite a decline in tech-related job postings,    
                             trends like gen AI and electrification showed      
                             positive job growth. The adoption of technologies  
                             follows an S-curve pattern, with varying levels of 
                             adoption across industries. Executives are         
                             encouraged to align their technology strategies    
                             with internal capacities and external ecosystem    
                             conditions to successfully integrate new           
                             technologies.                                      
[02/27/25 20:35:19] INFO     PromptTask 5c8be35339c64dbbab91af43fa8b3972        
                             Output: Here's a detailed examination of the newest
                             developments in AI as of 2024, highlighting major  
                             trends, breakthroughs, and their implications for  
                             various industries:                                

                             - **AI Index Report 2024**:                        
                               - AI's societal influence is growing, with       
                             advancements in technical capabilities and public  
                             perceptions.                                       
                               - AI has surpassed human performance in some     
                             areas but struggles with complex tasks.            
                               - Significant U.S. contributions in AI model     
                             production, with unprecedented training costs for  
                             models like GPT-4.                                 
                               - Generative AI funding surged despite a decline 
                             in overall AI investment.                          
                               - AI enhances productivity but poses risks       
                             without oversight, impacting labor and scientific  
                             discovery.                                         
                               - AI-related regulations in the U.S. have        
                             increased, with rising public concern about AI.    
                               - The report emphasizes responsible AI           
                             development, economic impacts, and educational     
                             trends.                                            

                             - **Generative AI Developments**:                  
                               - 2024 marks a pivotal year for generative AI,   
                             with a focus on trustworthiness, sustainability,   
                             and accessibility.                                 
                               - Multimodal AI is expected to enhance           
                             applications and virtual assistants.               
                               - Challenges include regulatory issues, potential
                             misuse, and the need for responsible AI adoption.  
                               - Businesses must adapt to emerging AI trends to 
                             maximize potential and minimize risks.             

                             - **Scientific Breakthroughs**:                    
                               - Advancements in green chemistry, CRISPR,       
                             biomaterials, and treatments for undruggable       
                             diseases.                                          
                               - AI impacts R&D, particularly in drug discovery 
                             and healthcare.                                    
                               - Green chemistry focuses on sustainable         
                             catalysts and recycling lithium-ion batteries.     
                               - CRISPR technology progresses in therapeutic    
                             applications for genetic diseases.                 
                               - Efforts to decarbonize energy include          
                             large-scale energy storage and nuclear power       
                             advancements.                                      

                             - **Generative AI in Business**:                   
                               - GenAI transforms business by enhancing         
                             productivity and streamlining operations.          
                               - Key developments include collaborations by     
                             companies like Cerebras Systems and OpenAI.        
                               - GenAI offers opportunities for content         
                             creation, personalized experiences, and task       
                             automation.                                        
                               - Managed service providers (MSPs) play a crucial
                             role in AI adoption, ensuring data security and    
                             offering training.                                 

                             - **McKinsey Technology Trends Outlook**:          
                               - Investments in generative AI and               
                             electrification promise substantial growth in      
                             enterprise adoption.                               
                               - Gen AI drives innovation in robotics and       
                             immersive reality.                                 
                               - Despite economic challenges, gen AI experienced
                             a sevenfold increase in investments.               
                               - Executives are encouraged to align technology  
                             strategies with internal capacities and external   
                             ecosystem conditions.                              

                             These insights reflect the dynamic landscape of AI 
                             in 2024, with significant implications for various 
                             industries, including healthcare, IT, retail, and  
                             energy.                                            
                    INFO     PromptTask 14c07d17702c4697ba018b4a7d7d1922        
                             Input: Instructions: Utilize the gathered insights 
                             to craft a captivating blog                        
                                             article showcasing the key AI      
                             innovations.                                       
                                             Ensure the content is engaging yet 
                             straightforward, appealing to a tech-aware         
                             readership.                                        
                                             Keep the tone appealing and use    
                             simple language to make it less technical.         
                             Context: Here's a detailed examination of the      
                             newest developments in AI as of 2024, highlighting 
                             major trends, breakthroughs, and their implications
                             for various industries:                            

                             - **AI Index Report 2024**:                        
                               - AI's societal influence is growing, with       
                             advancements in technical capabilities and public  
                             perceptions.                                       
                               - AI has surpassed human performance in some     
                             areas but struggles with complex tasks.            
                               - Significant U.S. contributions in AI model     
                             production, with unprecedented training costs for  
                             models like GPT-4.                                 
                               - Generative AI funding surged despite a decline 
                             in overall AI investment.                          
                               - AI enhances productivity but poses risks       
                             without oversight, impacting labor and scientific  
                             discovery.                                         
                               - AI-related regulations in the U.S. have        
                             increased, with rising public concern about AI.    
                               - The report emphasizes responsible AI           
                             development, economic impacts, and educational     
                             trends.                                            

                             - **Generative AI Developments**:                  
                               - 2024 marks a pivotal year for generative AI,   
                             with a focus on trustworthiness, sustainability,   
                             and accessibility.                                 
                               - Multimodal AI is expected to enhance           
                             applications and virtual assistants.               
                               - Challenges include regulatory issues, potential
                             misuse, and the need for responsible AI adoption.  
                               - Businesses must adapt to emerging AI trends to 
                             maximize potential and minimize risks.             

                             - **Scientific Breakthroughs**:                    
                               - Advancements in green chemistry, CRISPR,       
                             biomaterials, and treatments for undruggable       
                             diseases.                                          
                               - AI impacts R&D, particularly in drug discovery 
                             and healthcare.                                    
                               - Green chemistry focuses on sustainable         
                             catalysts and recycling lithium-ion batteries.     
                               - CRISPR technology progresses in therapeutic    
                             applications for genetic diseases.                 
                               - Efforts to decarbonize energy include          
                             large-scale energy storage and nuclear power       
                             advancements.                                      

                             - **Generative AI in Business**:                   
                               - GenAI transforms business by enhancing         
                             productivity and streamlining operations.          
                               - Key developments include collaborations by     
                             companies like Cerebras Systems and OpenAI.        
                               - GenAI offers opportunities for content         
                             creation, personalized experiences, and task       
                             automation.                                        
                               - Managed service providers (MSPs) play a crucial
                             role in AI adoption, ensuring data security and    
                             offering training.                                 

                             - **McKinsey Technology Trends Outlook**:          
                               - Investments in generative AI and               
                             electrification promise substantial growth in      
                             enterprise adoption.                               
                               - Gen AI drives innovation in robotics and       
                             immersive reality.                                 
                               - Despite economic challenges, gen AI experienced
                             a sevenfold increase in investments.               
                               - Executives are encouraged to align technology  
                             strategies with internal capacities and external   
                             ecosystem conditions.                              

                             These insights reflect the dynamic landscape of AI 
                             in 2024, with significant implications for various 
                             industries, including healthcare, IT, retail, and  
                             energy.                                            
[02/27/25 20:35:27] INFO     PromptTask 14c07d17702c4697ba018b4a7d7d1922        
                             Output: **Navigating the AI Frontier: Key          
                             Innovations of 2024**                              

                             As a Tech Content Strategist, I am thrilled to     
                             delve into the transformative landscape of         
                             artificial intelligence in 2024. This year marks a 
                             significant milestone in AI's journey, with        
                             groundbreaking advancements that are reshaping     
                             industries and redefining possibilities. The AI    
                             Index Report 2024 provides a comprehensive overview
                             of these developments, highlighting AI's growing   
                             societal influence and the challenges that         
                             accompany its rapid evolution.                     

                             One of the most exciting areas of progress is      
                             generative AI, which has seen a surge in funding   
                             despite a general decline in AI investments. This  
                             year, generative AI has focused on enhancing       
                             trustworthiness, sustainability, and accessibility.
                             Multimodal AI, which integrates multiple forms of  
                             data, is set to revolutionize applications and     
                             virtual assistants, offering more seamless and     
                             intuitive user experiences. However, with these    
                             advancements come challenges, including regulatory 
                             hurdles and the potential for misuse. Businesses   
                             must navigate these complexities to harness AI's   
                             full potential while mitigating risks.             

                             In the realm of scientific breakthroughs, AI is    
                             making significant strides in fields like green    
                             chemistry, CRISPR, and biomaterials. These         
                             advancements are particularly impactful in drug    
                             discovery and healthcare, where AI is accelerating 
                             research and development. Green chemistry          
                             innovations, such as sustainable catalysts and     
                             lithium-ion battery recycling, are paving the way  
                             for a more sustainable future. Meanwhile, CRISPR   
                             technology continues to advance, offering promising
                             therapeutic applications for genetic diseases.     
                             Efforts to decarbonize energy are also gaining     
                             momentum, with large-scale energy storage and      
                             nuclear power advancements leading the charge.     

                             Generative AI is not only transforming scientific  
                             research but also revolutionizing business         
                             operations. Companies like Cerebras Systems and    
                             OpenAI are at the forefront of this transformation,
                             collaborating to enhance productivity and          
                             streamline operations. Generative AI offers        
                             businesses opportunities for content creation,     
                             personalized experiences, and task automation.     
                             Managed service providers (MSPs) play a crucial    
                             role in facilitating AI adoption, ensuring data    
                             security, and providing necessary training. As     
                             businesses adapt to these emerging trends, they    
                             must align their technology strategies with both   
                             internal capacities and external ecosystem         
                             conditions to maximize growth and innovation.      

                             In conclusion, the dynamic landscape of AI in 2024 
                             presents both opportunities and challenges across  
                             various industries. From healthcare to energy, AI  
                             is driving innovation and reshaping the way we     
                             approach complex problems. As we continue to       
                             explore the potential of AI, it is crucial to      
                             prioritize responsible development and adoption,   
                             ensuring that these technologies benefit society as
                             a whole. The future of AI is bright, and with      
                             careful navigation, we can unlock its full         
                             potential to create a more sustainable and         
                             equitable world.                                   

Assistant Task

The Assistant Task enables Structures to interact with various "assistant" services using Assistant Drivers.

import os

from griptape.drivers.assistant.griptape_cloud import GriptapeCloudAssistantDriver
from griptape.structures import Pipeline
from griptape.tasks import AssistantTask

pipeline = Pipeline(
    tasks=[
        AssistantTask(
            assistant_driver=GriptapeCloudAssistantDriver(
                assistant_id=os.environ["GT_CLOUD_ASSISTANT_ID"],
            ),
        ),
    ]
)

pipeline.run("Hello!")
[02/27/25 20:26:52] INFO     AssistantTask a951a028b50e4349856c21c8eb916ebe     
                             Input: Hello!                                      
[02/27/25 20:26:55] INFO     AssistantTask a951a028b50e4349856c21c8eb916ebe     
                             Output: Hello! 😊 How can I assist you today?      

Text to Speech Task

This Task enables Structures to synthesize speech from text using Text to Speech Drivers.

import os

from griptape.drivers.text_to_speech.elevenlabs import ElevenLabsTextToSpeechDriver
from griptape.structures import Pipeline
from griptape.tasks import TextToSpeechTask

driver = ElevenLabsTextToSpeechDriver(
    api_key=os.environ["ELEVEN_LABS_API_KEY"],
    model="eleven_multilingual_v2",
    voice="Matilda",
)

task = TextToSpeechTask(
    text_to_speech_driver=driver,
)

Pipeline(tasks=[task]).run("Generate audio from this text: 'Hello, world!'")
[02/27/25 20:35:28] INFO     TextToSpeechTask d8e400e543fb4bebb4e34bb6304bf11a  
                             Input: Generate audio from this text: 'Hello,      
                             world!'                                            
[02/27/25 20:35:30] INFO     TextToSpeechTask d8e400e543fb4bebb4e34bb6304bf11a  
                             Output: Audio, format: mp3, size: 48901 bytes      

Audio Transcription Task

This Task enables Structures to transcribe speech from text using Audio Transcription Drivers.

from griptape.drivers.audio_transcription.openai import OpenAiAudioTranscriptionDriver
from griptape.loaders import AudioLoader
from griptape.structures import Pipeline
from griptape.tasks import AudioTranscriptionTask

driver = OpenAiAudioTranscriptionDriver(model="whisper-1")

task = AudioTranscriptionTask(
    input=lambda _: AudioLoader().load("tests/resources/sentences2.wav"),
    audio_transcription_driver=driver,
)

Pipeline(tasks=[task]).run()
[02/27/25 20:25:41] INFO     AudioTranscriptionTask                             
                             efee4d97329f4fad90d1fe2e79775a59                   
                             Input: Audio, format: wav, size: 628642 bytes      
[02/27/25 20:25:42] INFO     AudioTranscriptionTask                             
                             efee4d97329f4fad90d1fe2e79775a59                   
                             Output: Fill the ink jar with sticky glue. He      
                             smoked a big pipe with strong contents. We need    
                             grain to keep our mules healthy. Pack the records  
                             in a neat thin case. The crunch of feet in the snow
                             was the only sound. The copper bowl shone in the   
                             sun's rays. Boards will warp unless kept dry. The  
                             plush chair leaned against the wall. Glass will    
                             clink when struck by metal. Bathe and relax in the 
                             cool green grass.