The Treasury of Scriptural Knowledge puts it this way:
The word: This, and the four following chapters, record the events which occurred in Judea from the taking of Jerusalem [by the Babylonians/Chaldeans) to the retreat of the remnant of the people to Egypt; and contain several prophecies of Jeremiah concerning them there; which were “the word which came to Jeremiah from the Lord.”
The next two chapters in Jeremiah are not prophetic but historical events in and around Judah. They are the immediate events as they unfold after Jerusalem falls for the last time to Babylon and what consequently happens to Jeremiah.
Immediately following the fall of Jerusalem/Judah, Jeremiah is treated just as were the rest of the Judean prisoners; harshly and in chain bonds. Nebuchadnezzar’s order to treat him kindly had not yet reached his forces who were busy capturing fleeing and native Judeans Jews. So much happens during the first few days that follow the Chaldeans (Babylonians) invading Jerusalem. Things like robbing the Temple of its gold and silver artifacts and valuables, burning the city, chain-ganging the captives, taking spoils of cattle, and beginning rough treatment of the Jews. God took note of their cruel treatment. We will discuss this later in this Jeremiah series. It has deadly consequences for the Babylonians.
Why would there eventually be bad consequences on the Babylonians. This is actually addressed in verse 2…(ESV) “The captain of the guard took Jeremiah and said to him, “The LORD your God pronounced this disaster against this place.” They somehow KNEW that they conquered the kingdom of Judah because JUDAH’S GOD ALLOWED IT TO HAPPEN. This is the only place in scripture where this is suggested but we need to follow the Babylonians through to their end when the Persians and Medes destroy them when Daniel is very old. But consider the rough treatment of these people originally appointed by God to represent him. We should go back to Genesis 12:3a…[NIV] “I will bless those who bless you, and whoever curses you I will curse.”
Jeremiah 40:4, 5 are heartwarming verses showing the respect the Babylonians had for Jeremiah. This did not, however, ingratiate him with some of his kin and fellow Jews. Later on they forcibly take him to Egypt as they themselves flee Judah. We will study this in a later chapter of Jeremiah. This is also where legend begins to mix with scripture in per Jeremiah’s life.
Verse 7c gives us a pretty good clue as to who remained in Judah after the fact…”those of the poorest of the land.” When someone is busy trying to keep shelter over his or her head and food to eat, their involvement of current events are shallow. They must take care of their personal needs first. Many of these people knew or cared little about Jeremiah.
At verse 11 of Jeremiah 40, we shift gears. Those who had fled ahead of the Chaldean invasion or had previously left the Kingdom of Judah for whatever reason, heard that Nebuchadnezzar had appointed a new governor and only left a remnant of Judeans in their former country. Some who had fled began returning to occupy their homes or farms and buildings left standing from those who had been taken captive.
When the Babylonians conquered the people of Judah, there were some remaining Judean military captains and their men who escaped into the mountains and outer country side at the time of the invasion. Some were stationed at outposts and only later found out about the fall of their kingdom. They had to choose whether they would continue the fight as an underground resistance or submit to Babylonian rule. Gedaliah tried to persuade them that it would be wise and to their advantage to simply come back into the cities and live in peace serving the Babylonians.
JIV NOTE: There is historical significance of Mizpah where the appointed governor of Judah Gedaliah set up his capital. [To read about this go to Joshua 11:8, Judges 20:1-3, even back in Genesis 31:45-49].
Why would the governor who was appointed by Nebuchadnezzar set up his governorship ij Jerusalem? Simple. The Chaldeans had destroyed it, the temple and the walls. It was burned and little more than rubble at this time.
Sabotage! Insurrection! Plotting! At verse 14 we discover that all is still not well. Once more the Ammonites wish to continue their grudge blood feud with any of the Tribes of Jacob; i.e. this time only against the remnant in Judah and their newly appointed governor Gedaliah. `Dost thou really know that Baalis king of the sons of Ammon hath sent Ishmael son of Nethaniah to smite thy soul?‘ There are many theories but nothing concrete as to why Baalis specifically wanted to target Gedaliah. However, there is something of historical and current value to consider. Whatever it was on the heart of Baalis, it would have kept things stirred up in Judah by assassinating a Babylonian appointed governor. Just as is still true today, the world seems to keep things stirred up either in or about Israel. This is a spiritual war; Satan versus God.